NFT/ERC-721/Collectible TUTORIAL | Deploy, List on Opensea, Host Metadata on IPFS [See Description]
Why Ethereum Stack Exchange recommends it
Ethereum Stack Exchange users link it as the walkthrough they follow when learning to build NFTs with Brownie, and they cite it when asking about setup errors or extending the contract.
Recommended by 1 people across 1 different months, 2021 to 2021.
Why Stack Overflow recommends it
Stack Overflow users link it as the tutorial they were following when they hit Brownie, YAML config, import and gas estimation errors while deploying NFT contracts.
Recommended by 1 people across 1 different months, 2021 to 2022.
What it is
A 2h12m end-to-end tutorial by Patrick Collins on building an ERC-721 NFT collectible using Python and Brownie. It covers writing and deploying the contract, using Chainlink VRF for randomness, hosting metadata on IPFS and listing the tokens on OpenSea. The description lists later fixes for common errors and links an updated GitHub repo.
What people said
Recommends Kyle Lynch · 2021-08 · Ethereum Stack Exchange · on “How can I make an ERC721 NFT such that the token owner can edit an attribute in the metadata? Where can they edit the metadata?”
I was able to get Patrick's solution above to work on Rinkeby. Although I'm not concerned with changing the offchain metadata but it is only a matter of changing the tokenURI. If you haven't yet, work through Patrick's tutorial: [this video] then add Patrick's code above. You'll then need to make another file (call it change_metadata.py if writing in python) to call the function like: transaction = simple_collectible.changeAttributes(new_given_name, token_id, {"from": dev})
Recommends PIER FRANCESCO · 2022-09 · Stack Overflow · on “Goerli ValueError: Gas estimation failed: 'execution reverted'”
I'm trying to deploy an NFT about Harry Potter following this tutorial: [this video] . But when I run create_collectible.py I have an error: ValueError: Gas estimation failed: 'execution reverted'. This transaction will likely revert. If you wish to broadcast, you must set the gas limit manually. FULL ERROR OUTPUT File "brownie/_cli/run.py", line 51, in main return_value, frame = run( File "brownie/project/scripts.py", line 110, in run return_value = f_locals[method_name](*args, **kwargs) File "./scripts/advanced_collectible/create_collectible.py", line 12, in main transaction = advanced_collectible.createCollectible( File "brownie/network/contract.py", line 1861, in __call__ return self.transact
Cites Burtininkas · 2021-08 · Stack Overflow · on “ScannerError in brownie-config.yaml”
I am following this guide: [this video] (26:23) I typed everything in the brownie-cinfig.yaml like in the video dependencies: — OpenZeppelin/openzeppelin—contracts@3.4.0 — smartcontractkit/chainlink—brownie—contracts@1.0.2 compiler: solc: remappings: — '@openzeppelin=OpenZeppelin/openzeppelin—contracts@3.4.0' — '@chainlink=smartcontractkit/chainlink—brownie—contracts@1.0.2' But I get this error: File "yaml/scanner.py", line 291, in stale_possible_simple_keys raise ScannerError("while scanning a simple key", key.mark, ScannerError: while scanning a simple key in "/mnt/c/Users/Public/nft-from-scratch/brownie-config.yaml", line 3, column 1 could not find expected ':' in "/mnt/c/Users/Public/nft-from
Cites ChristianOConnor · 2021-10 · Ethereum Stack Exchange · on “Brownie, Where do I put my Infura API Key... not The ID, The Actual Key?”
I am learning how to us brownie for NFTs [this video] and I don't know where to put my infura API Key. I see in the Github repo that the .env file looks like this: export PRIVATE_KEY=asafdagadd export WEB3_INFURA_PROJECT_ID=asdfsdf But where does the API key go? Just the ID won't let me make API calls right?
Cites Hassif Imran · 2021-11 · Ethereum Stack Exchange · on “ValueError: Dotenv specified in config but not found at path”
Hello there I'm currently following this tutorial by Patrick Collins [this video] however I'm stuck at deploy script. PS C:\Users\aixax\Desktop\nft-from-scratch> brownie run scripts/advanced_collectible/deploy_advanced.py INFO: Could not find files for the given pattern(s). Brownie v1.17.1 - Python development framework for Ethereum File "C:\Users\aixax\AppData\Local\Programs\Python\Python310\lib\site-packages\eth_brownie-1.17.1-py3.10.egg\brownie\_cli\__main__.py", line 64, in main importlib.import_module(f"brownie._cli.{cmd}").main() File "C:\Users\aixax\AppData\Local\Programs\Python\Python310\lib\site-packages\eth_brownie-1.17.1-py3.10.egg\brownie\_cli\run.py", line 41, in main active_project.
Cites Vince Berry · 2022-02 · Stack Overflow · on “can't import module from solidity file to python file in brownie; ImportError: cannot import name 'AdvancedCollectible' from 'brownie'”
I'm trying to build out this [this video] tutorial, but I keep getting the same error when I try to import from a solidity file to a python script and run it, all in the same environment via brownie. I'm using this command in my local terminal: 'brownie run scripts/advanced_collectible/deploy_advanced.py' And I keep getting this error: ImportError: cannot import name 'AdvancedCollectible' from 'brownie' The solidity contract function is called AdvancedCollectible and it is in a file located at build/contracts/AdvancedCollectible.sol in the same local directory. The python script calls "from brownie import AdvancedCollectible" Everything is spelled correctly in both files, so I'm not sure what the
Cites Siqueira · 2022-05 · Stack Overflow · on “Gas estimation failed: 'invalid opcode: INVALID'. This transaction will likely revert. If you wish to broadcast, you must set the gas limit manually”
I adapted the code from this tutorial [this video] for my needs. It works fine at rinkeby network, but I am getting an error when I try to run it on Mumbai network. AdvancedCollectible.sol >> pragma solidity 0.6.6; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@chainlink/contracts/src/v0.6/VRFConsumerBase.sol"; contract AdvancedCollectible is ERC721 { bytes32 internal keyHash; uint256 public fee; event requestedCollectible(address indexed senderAdd); uint256 public tokenCounter; struct Remedio { string nome_medicamento; uint256 dosagem; string farmaceutica; string posologia; } enum Breed{PUG, SHIBA_INU, ST_BERNARD} mapping(uint256 => address) public requestIdToSender; mapping(