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

Upgrade to Polkadot v1.0.0 #302

Merged
merged 4 commits into from
Oct 10, 2023
Merged

Upgrade to Polkadot v1.0.0 #302

merged 4 commits into from
Oct 10, 2023

Conversation

@jasl jasl force-pushed the polkadot-v1.0.0 branch 2 times, most recently from 3756413 to a8a4cee Compare September 19, 2023 23:34
)?;

Self::deposit_event(Event::OriginOfShellMinted {
rarity_type,
collection_id: origin_of_shell_collection_id,
collection_id: origin_of_shell_collection_id.into(),
nft_id,
Copy link
Contributor

Choose a reason for hiding this comment

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

I see most have nft_id.into() but others do not. Do they all need to have .into()?

Copy link
Contributor Author

@jasl jasl Sep 20, 2023

Choose a reason for hiding this comment

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

Basically PW pallet use CollectionId and NftId from rmrk-primitives, which are not associate type CollectionId and ItemId, so it has to convert.

I do not change PW codes too much, only add into() when the compiler says error.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The error looks like this

error[E0308]: mismatched types
    --> pallets/phala-world/src/nft_sale.rs:1581:19
     |
1581 |             collection_id: origin_of_shell_collection_id,
     |                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected associated type, found `u32`
     |
     = note: expected associated type `<T as pallet_rmrk_core::Config>::CollectionId`
                           found type `u32`
     = help: consider constraining the associated type `<T as pallet_rmrk_core::Config>::CollectionId` to `u32` or calling a method that returns `<T as pallet_rmrk_core::Config>::CollectionId`
     = note: for more information, visit https://doc.rust-lang.org/book/ch19-03-advanced-traits.html
help: call `Into::into` on this expression to convert `u32` into `<T as pallet_rmrk_core::Config>::CollectionId`
     |
1581 |             collection_id: origin_of_shell_collection_id.into(),
     |                                                         +++++++

For more information about this error, try `rustc --explain E0308`.

Copy link
Contributor

@tolak tolak left a comment

Choose a reason for hiding this comment

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

SubBridge & inDEX looks good to me, btw already update sygma to include this fix

@jasl
Copy link
Contributor Author

jasl commented Oct 10, 2023

@h4x3rotab I'm merging this now, feel free to review later

@jasl jasl merged commit 3aa034a into main Oct 10, 2023
1 check passed
@jasl jasl deleted the polkadot-v1.0.0 branch October 10, 2023 11:37
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