feat: add Firo chain support to asset-calculator#18
Closed
reubenyap wants to merge 3 commits intorosen-bridge:devfrom
Closed
feat: add Firo chain support to asset-calculator#18reubenyap wants to merge 3 commits intorosen-bridge:devfrom
reubenyap wants to merge 3 commits intorosen-bridge:devfrom
Conversation
- Register `firo` in the `NETWORKS` constant (no token support, native
token `firo`).
- Add `FiroCalculator` that reads locked amounts from the Firo
insight-api (`/insight-api-zcoin/addr/{address}/balance`).
- Add `FiroCalculatorInterface` and register `FiroCalculator` in
`AssetCalculator`.
Part of the RCS-003 Bridge Expansion Kit for Firo.
|
@reubenyap is attempting to deploy a commit to the rosen-bridge Team on Vercel. A member of the Team first needs to authorize it. |
With firo in NETWORKS_KEYS but not yet in configs.chains, ChainChoices is wider than keyof typeof configs.chains. Adjust the two spots that index configs.chains[chain] so tsc stays green until the backend Firo config lands: - assetAggregator: cast chain to keyof typeof configs.chains at the index site. - assetDataAdapters: narrow createChainSpecificDataAdapter's chain parameter from ChainChoices to keyof typeof configs.chains (the switch never handled firo anyway), removing the now-unused ChainChoices import.
`path.posix.relative` cannot produce a correct relative path from two Windows-absolute paths, so `getKnipCommand` was emitting garbage like `knip --dependencies --workspace ../E:\Github\rosen-ui\packages\X`, which knip rejects as "Workspace is not a directory". This blocked pre-commit hooks on Windows for any commit touching package sources. Use the cross-platform `path.relative` and normalize separators to forward slashes (matching the existing type-check line that already uses `path.relative`).
Author
|
Superseded by #19. #19 now contains the full Firo asset-calculator change set (the three commits from this PR, minus the Windows lint-staged fix) plus the
The Windows-only Closing in favour of #19. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
firoin theNETWORKSconstant (no token support, native tokenfiro).FiroCalculatorthat reads locked amounts from the Firo insight-api (/insight-api-zcoin/addr/{address}/balance).FiroCalculatorInterfaceand registerFiroCalculatorinAssetCalculator.Part of the RCS-003 Bridge Expansion Kit for Firo.