kevinfaveri/solana-candy-factory

Buffer overrun (re-open)

doogyhatts opened this issue · 19 comments

Hi Kevin!
I got this error when I tried deploying mainnet for 10 items.
Writing indices 0-9 saving config line 0-9 failed RangeError: encoding overruns Buffer at Blob.encode...
I noticed a similar problem on devnet, where I could only batch 8 items at one time.

I have not deleted the cache for mainnet. I was charged a bit of Sol as well.
What should I do next?

I am reading the other issue on restarting uploads.

Hmm... which image format and which size?

Png format, size of 2048x1024.
I had actually uploaded them to Arweave before I run this program. But why would the image affect the program?

Can you send me a samples of your nfts JSON? This might be the name of your JSONs that are too long (and you need to be aware of that because the name in the JSON is stored on the Solana blockchain, not arweave, and thus has a limitation of size)

ok sent one to your email.
Do you know the character limits for the various entities?

It is the name. It should not be that long. Refrain to use a small prefix + #Number if you want to avoid this problem. I think the char limit is something like 32 chars

ok I will change it and redo the upload according to the previous issue.

Hmm... I reduced the name length to 22 characters and it retains the #Number.
But I am still getting same error.

ok I can try checking the cache first, before purging it.

I restarted the process and it went ok.

Hi Kevin!
I was wondering if I had another buffer overrun issue again. Devnet works ok, but not for mainnet.
Here is the error:
Writing indices 10-19 Transaction simulation failed: Error processing Instruction 0: custom program error: 0x12f Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ invoke [1] Program log: Custom program error: 0x12f Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ consumed 16902 of 200000 compute units Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ failed: custom program error: 0x12f Translating error SendTransactionError: failed to send transaction: Transaction simulation failed: Error processing Instruction 0: custom program error: 0x12f at Connection.sendEncodedTransaction (/Users/edwinzeng/metaplex-foundation/metaplex/js/node_modules/@solana/web3.js/src/connection.ts:3553:13) at processTicksAndRejections (internal/process/task_queues.js:95:5) at async Connection.sendRawTransaction (/Users/edwinzeng/metaplex-foundation/metaplex/js/node_modules/@solana/web3.js/src/connection.ts:3513:20) at async Object.sendAndConfirmRawTransaction (/Users/edwinzeng/metaplex-foundation/metaplex/js/node_modules/@solana/web3.js/src/util/send-and-confirm-raw-transaction.ts:27:21) at async Provider.send (/Users/edwinzeng/metaplex-foundation/metaplex/js/node_modules/@project-serum/anchor/src/provider.ts:112:18) at async Object.rpc [as addConfigLines] (/Users/edwinzeng/metaplex-foundation/metaplex/js/node_modules/@project-serum/anchor/src/program/namespace/rpc.ts:19:23) { logs: [ 'Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ invoke [1]', 'Program log: Custom program error: 0x12f', 'Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ consumed 16902 of 200000 compute units', 'Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ failed: custom program error: 0x12f' ] } saving config line 10-19 failed ProgramError: at Function.parse (/Users/edwinzeng/metaplex-foundation/metaplex/js/node_modules/@project-serum/anchor/src/error.ts:30:14) at Object.rpc [as addConfigLines] (/Users/edwinzeng/metaplex-foundation/metaplex/js/node_modules/@project-serum/anchor/src/program/namespace/rpc.ts:23:42) at processTicksAndRejections (internal/process/task_queues.js:95:5) { code: 303, msg: 'Index greater than length!' }

How should I resolve it this time?

I wonder if it was due to the long descriptions that I have. So I tried reducing them to a common 122 characters string but I am still having the error.

Quite odd though I increased the batch size from 10 files to 128. And the first 10 files was working well.
I didn't delete the previous cache, but I checked that it got overridden anyway.

I have checked that others are having this issue as well.
metaplex-foundation/metaplex#701

Oh wait, you increased from 10 files to 128? You can't do that. You should not have long names and you can't incrementally upload -- meaning you should upload them all at once. Since you updated the batch, you SHOULD delete the cache folder and run again OR just create another candy machine.

Also, can you share your cache file so I can take a look?

Are you using Windows, btw?

Ok sent the cache file to your email.
I am using a Mac.

But I tried to do uploading which gave the errors and that is before creating candy machine.

ya. But if you increased the batch from 10 to 128 without recreating the cache file this error will happen as the config account you created as made to accept only 10 not 128.

oh I see. Let me try to redo it again, this time clearing the cache.

ok resolved by clearing the cache and rerun mainnet deployment.

Hey! It seems like this is an ecosystem-wide error that is happening. I will take to take a more details look tomorrow or thursday.

On Tue, Oct 19, 2021 at 10:32 PM edwinzeng2005 @.> wrote: Hi Kevin! I was wondering if I had another buffer overrun issue again. Devnet works ok, but not for mainnet. Here is the error: Writing indices 10-19 Transaction simulation failed: Error processing Instruction 0: custom program error: 0x12f Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ invoke [1] Program log: Custom program error: 0x12f Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ consumed 16902 of 200000 compute units Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ failed: custom program error: 0x12f Translating error SendTransactionError: failed to send transaction: Transaction simulation failed: Error processing Instruction 0: custom program error: 0x12f at Connection.sendEncodedTransaction @./web3.js/src/connection.ts:3553:13) at processTicksAndRejections (internal/process/task_queues.js:95:5) at async Connection.sendRawTransaction @./web3.js/src/connection.ts:3513:20) at async Object.sendAndConfirmRawTransaction @./web3.js/src/util/send-and-confirm-raw-transaction.ts:27:21) at async Provider.send @./anchor/src/provider.ts:112:18) at async Object.rpc [as addConfigLines] @./anchor/src/program/namespace/rpc.ts:19:23) { logs: [ 'Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ invoke [1]', 'Program log: Custom program error: 0x12f', 'Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ consumed 16902 of 200000 compute units', 'Program cndyAnrLdpjq1Ssp1z8xxDsB8dxe7u4HL5Nxi2K5WXZ failed: custom program error: 0x12f' ] } saving config line 10-19 failed ProgramError: at Function.parse @./anchor/src/error.ts:30:14) at Object.rpc [as addConfigLines] @./anchor/src/program/namespace/rpc.ts:23:42) at processTicksAndRejections (internal/process/task_queues.js:95:5) { code: 303, msg: 'Index greater than length!' } How should I resolve it this time? — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#43 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AELA3INPLTCLKE2FVM3LVI3UHYL3RANCNFSM5GJKQLEA .

I'm getting the same issue? Are you avaiable to help ?