"ERC721PresetMinterPauserAutoId" hit an invalid opcode while deploying

Trying this sample nft;

[[DRAFT] Create an NFT and deploy to a public testnet, using Truffle](http://NFT Sample)

I could deploy it in Ganache but not on Rinkeby. I get the following.


   Deploying 'ERC721PresetMinterPauserAutoId'
Error:  *** Deployment Failed ***

"ERC721PresetMinterPauserAutoId" hit an invalid opcode while deploying. Try:
   * Verifying that your constructor params satisfy all assert conditions.
   * Verifying your constructor code doesn't access an array out of bounds.
   * Adding reason strings to your assert statements.

    at C:\Users\iando\AppData\Roaming\npm\node_modules\truffle\build\webpack:\packages\truffle-deployer\src\deployment.js:364:1
    at <anonymous>
Truffle v5.0.5 (core: 5.0.5)
Node v9.10.0
PS D:\Code\nftSample> 

What could cause this?

1 Like

Hi @madeindreams,

Welcome to the community :wave:

I have replied in: Deployment failed on Rinkeby: “ERC721PresetMinterPauserAutoId” hit an invalid opcode

I will close this topic and we can continue the discussion in the other topic.