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

πŸ’₯ Implement ERC-1155 Standard Token #31

Merged
merged 76 commits into from
Jan 15, 2023
Merged

πŸ’₯ Implement ERC-1155 Standard Token #31

merged 76 commits into from
Jan 15, 2023

Conversation

pcaversaccio
Copy link
Owner

@pcaversaccio pcaversaccio commented Dec 19, 2022

πŸ§™πŸΌβ€β™‚οΈ CHANGELOG

Closes #15. In addition to the standard EIP-1155 functionalities, we implement the following features:

🦠 Bug Fixes

  • We add to all constructors of the ERC20, ERC721, and ERC1155 contracts, the missing RoleMinterChanged event. Thanks, @jtriley-eth for pointing this out!
  • We fix the missing _before_token_transfer and _after_token_transfer hooks & the missing Transfer event in the ERC20 constructor.
  • We rename to to owner due to the sake of consistency in the internal mint functions _safe_mint and _mint of the ERC721 contract.
  • We add the missing IERC165 function supportsInterface to the interfaces IERC1155, IERC1155MetadataURI, IERC1155Receiver, IERC721Enumerable, IERC721Metadata, and IERC721Permit. We also fix the correct visibility modifier from @pure to @view.
  • We refactor the functions transfer_ownership and renounce_ownership in the ERC20, ERC721, and ERC1155 contracts in order to add missing events and automatically remove the previous owner's minter role and assign the minter role to new_owner accordingly.

πŸ“ Improved Documentation

  • We add missing EIP links to three ERC721 interfaces:

    • IERC721Enumerable
    • IERC721Receiver
    • IERC721Metadata
  • We add a note on return value bounds in Vyper interfaces to three interfaces where this is relevant:

    • IERC721Metadata
    • IERC1155MetadataURI
    • IERC1155
  • We add in the ERC20, ERC721, and ERC1155 contract documentation, which functions are view functions.

  • Fixes ♻️ Reorder README SequenceΒ #48.

πŸ‘―β€β™€οΈ Co-Author

Special thanks go to @jtriley-eth who co-authored this PR πŸ™πŸ½. He deserves the cheer!

Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
@pcaversaccio pcaversaccio self-assigned this Dec 19, 2022
@pcaversaccio pcaversaccio added the feature πŸ’₯ New feature or request label Dec 19, 2022
@pcaversaccio pcaversaccio changed the title πŸ€– ERC-4626 Tokenised Vault Implementation πŸ€– ERC-1155 Token Implementation Dec 19, 2022
pcaversaccio and others added 25 commits December 19, 2022 23:04
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Co-authored-by: Pascal Marco Caversaccio <pcaversaccio@users.noreply.github.com>
Signed-off-by: JT <Jtriley15@gmail.com>
Co-authored-by: Pascal Marco Caversaccio <pcaversaccio@users.noreply.github.com>
Signed-off-by: JT <Jtriley15@gmail.com>
Co-authored-by: Pascal Marco Caversaccio <pcaversaccio@users.noreply.github.com>
Signed-off-by: JT <Jtriley15@gmail.com>
Co-authored-by: Pascal Marco Caversaccio <pcaversaccio@users.noreply.github.com>
Signed-off-by: JT <Jtriley15@gmail.com>
Co-authored-by: Pascal Marco Caversaccio <pcaversaccio@users.noreply.github.com>
Signed-off-by: JT <Jtriley15@gmail.com>
Co-authored-by: Pascal Marco Caversaccio <pcaversaccio@users.noreply.github.com>
Signed-off-by: JT <Jtriley15@gmail.com>
Co-authored-by: Pascal Marco Caversaccio <pcaversaccio@users.noreply.github.com>
Signed-off-by: JT <Jtriley15@gmail.com>
Co-authored-by: Pascal Marco Caversaccio <pcaversaccio@users.noreply.github.com>
Signed-off-by: JT <Jtriley15@gmail.com>
Co-authored-by: Pascal Marco Caversaccio <pcaversaccio@users.noreply.github.com>
Signed-off-by: JT <Jtriley15@gmail.com>
`ERC1155MetadataURI` Implementation Logic
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
… view

Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
@pcaversaccio pcaversaccio marked this pull request as ready for review January 13, 2023 18:39
@pcaversaccio pcaversaccio added bug πŸ› Something isn't working optimisation ⚑️ Code optimisations (e.g. gas improvements) labels Jan 13, 2023
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
Copy link
Owner Author

@pcaversaccio pcaversaccio left a comment

Choose a reason for hiding this comment

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

@jtriley-eth LFG πŸ₯³

@pcaversaccio pcaversaccio merged commit b49e486 into main Jan 15, 2023
@pcaversaccio pcaversaccio deleted the erc1155 branch January 15, 2023 11:37
@pcaversaccio pcaversaccio changed the title πŸ€– ERC-1155 Token Implementation πŸ’₯ Implement ERC-1155 Standard Token Feb 1, 2023
@pcaversaccio pcaversaccio added this to the 0.0.1 milestone Feb 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug πŸ› Something isn't working feature πŸ’₯ New feature or request optimisation ⚑️ Code optimisations (e.g. gas improvements)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

♻️ Reorder README Sequence πŸ’₯ ERC-1155 Token Implementation
2 participants