-
Notifications
You must be signed in to change notification settings - Fork 82
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: implement ICS-721 NFT transfer application #1053
Merged
Merged
Conversation
This file contains 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
* chore: establish ics721 boilerplate, ready for new additions * nit
* WIP: add types and contexts * WIP: add events * WIP: implement modules * add send_transfer * add recv and refund handlers * add tests * fix send and recv * fix context and add tests * fix fmt * fix for CI * fix messages and serde * fix comments
…i` types (#1027) * WIP: add types and contexts * WIP: add events * WIP: implement modules * add send_transfer * add recv and refund handlers * add tests * fix send and recv * fix context and add tests * fix fmt * fix for CI * fix messages and serde * fix comments * Stub out DataValue Borsh unit test * Add basic borsh (de)ser roundtrip tests * Add basic serde roundtrip tests for DataValue * Add json (de)serialization tests * Add roundtrip tests for TokenUri * Add roundtrip tests for ClassUri * Remove ignore statement on a test * Resolve clippy warning * Change packet data dummy json strings to use camel case * Configure nft-transfer app under std feature flag * Move cfg statement * Add nft-transfer feature * Add nft-transfer feature * Remove nft-transfer feature from default features * Remove `optional = true` from `http` dependency --------- Co-authored-by: yito88 <[email protected]>
* trace hash with class ID and token ID * add serde flag
* fix encoding for ClassData and TokenData * fix Cargo.toml
* skip validation, make some data optional * check the length of token_uri and token_data * fix to set TokenData and TokenUri at once * imp: add validate_basic method for PacketData * imp: allow any format for Data + define parse_as_ics721_data method * fmt and clippy * custom serde packet data with option * add a test * restore conversions --------- Co-authored-by: Farhad Shabani <[email protected]>
rnbguy
approved these changes
Jan 23, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
I approved the PR but I think the changes in ics20 source code are mistakes.
Farhad-Shabani
added a commit
that referenced
this pull request
Sep 9, 2024
* feat: establish ICS-721 boilerplate, ready for new additions (#1012) * chore: establish ics721 boilerplate, ready for new additions * nit * Implement ICS-721 NFT transfer (#1020) * WIP: add types and contexts * WIP: add events * WIP: implement modules * add send_transfer * add recv and refund handlers * add tests * fix send and recv * fix context and add tests * fix fmt * fix for CI * fix messages and serde * fix comments * Add (de)serialization tests for `DataValue`, `TokenUri`, and `ClassUri` types (#1027) * WIP: add types and contexts * WIP: add events * WIP: implement modules * add send_transfer * add recv and refund handlers * add tests * fix send and recv * fix context and add tests * fix fmt * fix for CI * fix messages and serde * fix comments * Stub out DataValue Borsh unit test * Add basic borsh (de)ser roundtrip tests * Add basic serde roundtrip tests for DataValue * Add json (de)serialization tests * Add roundtrip tests for TokenUri * Add roundtrip tests for ClassUri * Remove ignore statement on a test * Resolve clippy warning * Change packet data dummy json strings to use camel case * Configure nft-transfer app under std feature flag * Move cfg statement * Add nft-transfer feature * Add nft-transfer feature * Remove nft-transfer feature from default features * Remove `optional = true` from `http` dependency --------- Co-authored-by: yito88 <[email protected]> * fix: calculate trace hash from both class ID and token ID (#1032) * trace hash with class ID and token ID * add serde flag * Fix ClassData and TokenData encoding in NonFungiblePacketData (#1038) * fix encoding for ClassData and TokenData * fix Cargo.toml * Support ClassData and TokenData not according to ICS-721 spec (#1039) * skip validation, make some data optional * check the length of token_uri and token_data * fix to set TokenData and TokenUri at once * imp: add validate_basic method for PacketData * imp: allow any format for Data + define parse_as_ics721_data method * fmt and clippy * custom serde packet data with option * add a test * restore conversions --------- Co-authored-by: Farhad Shabani <[email protected]> * chore: add unclog * nit: fix docstrings --------- Co-authored-by: Yuji Ito <[email protected]> Co-authored-by: Sean Chen <[email protected]> Co-authored-by: yito88 <[email protected]>
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.
Closes: #346
Description
This PR introduces the implementation of the ICS-721 NFT transfer application on the current
feat/ics721-impl
feature branch to themain
. It encompasses the following PRs:DataValue
,TokenUri
, andClassUri
types #1027PR author checklist:
unclog
.docs/
).Reviewer checklist:
Files changed
in the GitHub PR explorer.