Skip to content

add parachain c#699

Open
zqhxuyuan wants to merge 2 commits intoopen-web3-stack:masterfrom
zqhxuyuan:here-reanchor
Open

add parachain c#699
zqhxuyuan wants to merge 2 commits intoopen-web3-stack:masterfrom
zqhxuyuan:here-reanchor

Conversation

@zqhxuyuan
Copy link
Copy Markdown
Contributor

@zqhxuyuan zqhxuyuan commented Feb 20, 2022

some parachain may not use GeneralKey as its token, but use just its parachain, i.e. PHA:

https://github.com/AcalaNetwork/Acala/blob/d92b2db7e384ebf24dafc89d7cc0e04ee4724435/runtime/karura/src/lib.rs#L1811-L1812

// Phala Native token
Token(PHA) => Some(MultiLocation::new(1, X1(Parachain(parachains::phala::ID)))),

this PR add parachain c, and use parachain(3) to represent its token.

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Feb 20, 2022

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.74%. Comparing base (4a66b29) to head (f87e99f).
⚠️ Report is 222 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #699      +/-   ##
==========================================
+ Coverage   74.63%   74.74%   +0.11%     
==========================================
  Files          83       83              
  Lines        7261     7293      +32     
==========================================
+ Hits         5419     5451      +32     
  Misses       1842     1842              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@xlc xlc requested a review from shaunxw February 20, 2022 05:41
X1(GeneralKey(k)) if k == b => Some(CurrencyId::B),
X1(GeneralKey(k)) if k == a1 => Some(CurrencyId::A1),
X1(GeneralKey(k)) if k == b1 => Some(CurrencyId::B1),
Here => Some(CurrencyId::C),
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Parachains in mock shares the same CurrencyIdConvert, this will make all of them convert Here to CurrencyId::C, which doesn't make sense.

You'll need to define a convert impl only for Parachain C.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants