metaplex-foundation / metaplex

A directory of what the Metaplex Foundation works on!
https://metaplex.com
Apache License 2.0
3.32k stars 6.26k forks source link

[Bug]: 9 NFTs remaining but sold out #1763

Closed SamFordGH closed 2 years ago

SamFordGH commented 2 years ago

Which package is this bug report for?

candy machine ui

Issue description

When running the candy machine mint in browser, it says there are 9 NFTs remaining, however when you click the mint button it says sold out...

Screenshot 2022-02-10 at 11 47 40

Command

No response

Relevant log output

No response

Operating system

Mac

Priority this issue should have

Low (slightly annoying)

Check the Docs First

walter-grace commented 2 years ago

I can confirm I was having this exact issue after updating the yarn and package.json files from the PR https://github.com/metaplex-foundation/metaplex/commit/d9a4bbde3cabef5c33f14c3a33d3d72c2938e045 My mint says it was sold out to

Screen Shot 2022-02-10 at 8 46 12 AM

o

Levdown commented 2 years ago

have the same issue

BENMOU98 commented 2 years ago

The same issue

bxuserx commented 2 years ago

Same, it prevented my mint today. :(

stegaBOB commented 2 years ago

I think the mint is actually sold out, but the UI hasn't updated fast enough. When you set your price that low and don't have a captcha, this is bound to happen. Bots :/

bxuserx commented 2 years ago

So wait, 5 people have reported this issue. I have run the ts-node candy-machine-V2-cli.ts get_all_mint_addresses and can confirm that only the two I preminted (command line) have been minted, with 98 left unsold... and this issue is being closed?

I've successfully ran 3 other candy machine mints, can confirm this is a real issue.

I'll drop back to an older release for the time being, and recommend others not to use the latest release in the mean time.

bxuserx commented 2 years ago

comparing an old working candy machine with a new one, I think it has something to do with the migration from the 'BLOCKHASHES_PUBKEY' to the 'SLOT_HASHES_PUBKEY'. Went into Anchor web3 API but couldn't find these system variables.

Screen Shot 2022-02-15 at 12 08 18 AM
stegaBOB commented 2 years ago

That could also be it. A recent change in Solana forced us to update the candy machine.

On Mon, Feb 14, 2022, 11:12 PM bxuser @.***> wrote:

comparing an old working candy machine with a new one, I think it has something to do with the migration from the 'BLOCKHASHES_PUBKEY' to the 'SLOT_HASHES_PUBKEY'. Went into Anchor web3 API but couldn't find these system variables. [image: Screen Shot 2022-02-15 at 12 08 18 AM] https://user-images.githubusercontent.com/86570251/153996715-f88678b6-62d3-434f-b08c-f49a49aed343.png

— Reply to this email directly, view it on GitHub https://github.com/metaplex-foundation/metaplex/issues/1763#issuecomment-1039866043, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJ5KTMB63R54VODEFXLRWHDU3HODPANCNFSM5OAOREYA . You are receiving this because you modified the open/close state.Message ID: @.***>

bxuserx commented 2 years ago

Went back to an old version of metaplex, mint is now working. Pretty sure now that it's an issue with the slot hashing vs block hashing. Looks like anchor's API might not be matching the state correctly to query the number remaining, and is defaulting to a 'sold out' error message.

Since I use a .art extension on my site, I'm forced to use the project serum API in my .env instead of the default for candy machine. Perhaps this could be related too/instead?

Not sure though. Only changing the variable above and rebuilding didn't fix it. Had to start from an older version completely.