Metaplex Core NFTのCollectionをCompressed NFTに紐付けると「AccountNotInitialized」エラー

前提

  • CollectionはCore NFTで作成
  • Compressed NFTは未作成。上記Collectionに紐付けて作成したい

現象

Core NFTで作成したCollectionをCompressed NFTに紐付けてMintを試したところ、以下のエラーが発生。

ts-node src/mintToCollection.ts
/Users/metaplex/bubblegum_CompressedNFT/node_modules/@solana/web3.js/src/connection.ts:5920
      throw new SendTransactionError(
            ^
SendTransactionError: failed to send transaction: Transaction simulation failed: Error processing Instruction 0: custom program error: 0xbc4
    at Connection.sendEncodedTransaction (/Users/metaplex/bubblegum_CompressedNFT/node_modules/@solana/web3.js/src/connection.ts:5920:13)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async Connection.sendRawTransaction (/Users/metaplex/bubblegum_CompressedNFT/node_modules/@solana/web3.js/src/connection.ts:5879:20)
    at async Object.sendTransaction (/Users/metaplex/bubblegum_CompressedNFT/node_modules/@metaplex-foundation/umi-rpc-web3js/src/createWeb3JsRpc.ts:327:25)
    at async TransactionBuilder.sendAndConfirm (/Users/metaplex/bubblegum_CompressedNFT/node_modules/@metaplex-foundation/umi/src/TransactionBuilder.ts:359:23)
    at async mintToCollection (/Users/metaplex/bubblegum_CompressedNFT/src/mintToCollection.ts:47:22) {
  logs: [
    'Program BGUMAp9Gq7iTEuizy4pqaxsTyUCBK68MDfK752saRPUY invoke [1]',
    'Program log: Instruction: MintToCollectionV1',
    'Program log: AnchorError caused by account: collection_metadata. Error Code: AccountNotInitialized. Error Number: 3012. Error Message: The program expected this account to be already initialized.',
    'Program BGUMAp9Gq7iTEuizy4pqaxsTyUCBK68MDfK752saRPUY consumed 11110 of 200000 compute units',
    'Program BGUMAp9Gq7iTEuizy4pqaxsTyUCBK68MDfK752saRPUY failed: custom program error: 0xbc4'
  ]
}

原因

おそらく、Core NFTで作成したCollectionをCompressed NFTに紐付けることができないっぽい。

対応

Standard NFTでCollectionを作成してから、Compressed NFTに紐付ける。