Solana MetaplexのMetabossでURI更新すると「custom program error: 0x7」エラー

現象

Metaboxx - Update the URI of an existing NFT を試したところ、「0x7」エラーが発生。

% metaboss update uri -k ~/.config/solana/devnet.json -a 6fz3V6mSDiKuzgLcPSfvnBu8ZiLjcMmaRkbpqcT4Qgpn -u https://arweave.net/N36gZYJ6PEH8OE11i0MppIbPG4VXKV4iuQw1zaq3rls

[2022-05-20T20:27:58Z WARN  metaboss] Using a public RPC URL is not recommended for heavy tasks as you will be rate-limited and suffer a performance hit.
            Please use a private RPC endpoint for best performance results.
Error: RPC response error -32002: Transaction simulation failed: Error processing Instruction 0: custom program error: 0x7 [5 log messages]

Caused by:
    RPC response error -32002: Transaction simulation failed: Error processing Instruction 0: custom program error: 0x7 [5 log messages]

原因

更新権限がない。Update AuthorityとMetabossで指定したアドレスが異なるため、更新ができない。

対応

Update Authorityのアドレスを指定する。(今回のケースは、dev.jsonではなく、id.jsonがUpdate Authorityだったので、id.jsonを指定)

% metaboss update uri -k ~/.config/solana/id.json -a 6fz3V6mSDiKuzgLcPSfvnBu8ZiLjcMmaRkbpqcT4Qgpn -u https://arweave.net/N36gZYJ6PEH8OE11i0MppIbPG4VXKV4iuQw1zaq3rls

[2022-05-20T20:30:49Z WARN  metaboss] Using a public RPC URL is not recommended for heavy tasks as you will be rate-limited and suffer a performance hit.
            Please use a private RPC endpoint for best performance results.
Tx sig: 31vtUCb44LbBR7QDp2yda1SM449wKUYj1wKLSmWLfegLYJhjvK7KyA2sqt4amx4fR5LE1CCWsCNaCsySHzPvFx4V
Done!

参考

Candy Machine Errors

Token Metadata, Description
7,  UpdateAuthorityIncorrect: Update Authority given does not match