Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/fvm mainnet minter support #247

Merged
merged 3 commits into from
Jan 21, 2025
Merged

Conversation

bitbeckers
Copy link
Contributor

  • Adds support for FVM minter contract on filecoin mainnet
  • Refactor the evmClient and chainsauce builders to use the newly implemented ChainFactory and RpcFactory. This is because both files needed to be updated and we introduced a few exceptions for different chains. This refactor should make the code more readable, testable and maintainable.
  • Tests suites updated accordingly.

Adds filecoin to the evmClient and chainsauce client constructor.
Updates seed file to index minter contract on filecoin mainnet
When adding another chain, this needed to happen in multiple files. This
is also true for setting a custom fetch client when we need to apss
bearer tokens.

This commit refactors the evmClient and chainsauce builder to rely on a
ChainFactory and RpcFactory to give both clients a consistent config
depending on the selected chain.

Test cases were added and failing tests were updated to respect the new
pattern
Adds support for the fallback provider pattern in viem. Tests updated
accordingly.
@bitbeckers bitbeckers added the enhancement New feature or request label Jan 21, 2025
@bitbeckers bitbeckers requested a review from Jipperism January 21, 2025 16:44
@bitbeckers bitbeckers self-assigned this Jan 21, 2025
Copy link

Coverage Report

Status Category Percentage Covered / Total
🟢 Lines 27.2% (🎯 27%) 1680 / 6175
🟢 Statements 27.2% (🎯 27%) 1680 / 6175
🟢 Functions 70.9% (🎯 70%) 39 / 55
🟢 Branches 72.91% (🎯 72%) 105 / 144
File Coverage
File Stmts Branches Functions Lines Uncovered Lines
Changed Files
src/clients/chainFactory.ts 97.43% 80% 100% 97.43% 37
src/clients/evmClient.ts 100% 100% 100% 100%
src/clients/rpcClientFactory.ts 100% 100% 100% 100%
Generated in workflow #202 for commit fc5e110 by the Vitest Coverage Report Action

@bitbeckers bitbeckers merged commit 2ac3d9f into develop Jan 21, 2025
2 checks passed
@bitbeckers bitbeckers deleted the feat/fvm_mainnet_minter_support branch January 22, 2025 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

1 participant