Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Explorer doesn't show unwrapped objects in the transaction summary #4727

Open
Thoralf-M opened this issue Jan 9, 2025 · 1 comment
Open
Labels
explorer Issues related to the Explorer

Comments

@Thoralf-M
Copy link
Member

Bug description

A transaction like https://explorer.rebased.iota.org/txblock/6nQ7pwn2vwU296AnrNAkgRZsnht4gTcrTnFKfPVer1y4 that unwraps an object from another one, doesn't show the unwrapped object in the balance changes, making it unclear what happened.
Here are the transaction details from the CLI where the missing object is listed in Unwrapped Objects:

Transaction Digest: 6nQ7pwn2vwU296AnrNAkgRZsnht4gTcrTnFKfPVer1y4
╭─────────────────────────────────────────────────────────────────────────────────────────────────╮
│ Transaction Data                                                                                │
├─────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Sender: 0x111111111504e9350e635d65cd38ccd2c029434c6a3a480d8947a9ba6a15b215                      │
│ Gas Owner: 0x111111111504e9350e635d65cd38ccd2c029434c6a3a480d8947a9ba6a15b215                   │
│ Gas Budget: 10000000 NANOS                                                                      │
│ Gas Price: 1000 NANOS                                                                           │
│ Gas Payment:                                                                                    │
│  ┌──                                                                                            │
│  │ ID: 0x003ff7f0e4940d94e56729949db16875806aa4b5bc816469ce7c76da2744f3a3                       │
│  │ Version: 6809040                                                                             │
│  │ Digest: Cna6vsobAp3Tg6ALsmSwvncnCeYk4ZFUDPvyyuL6yCV9                                         │
│  └──                                                                                            │
│                                                                                                 │
│ Transaction Kind: Programmable                                                                  │
│ ╭─────────────────────────────────────────────────────────────────────────────────────────────╮ │
│ │ Input Objects                                                                               │ │
│ ├─────────────────────────────────────────────────────────────────────────────────────────────┤ │
│ │ 0   Shared Object    ID: 0xb1b2c1f2f2e33943e8fe7954fca9da40b56cd33cf89c00ac1a45f7a1b028ec11 │ │
│ ╰─────────────────────────────────────────────────────────────────────────────────────────────╯ │
│ ╭──────────────────────────────────────────────────────────────────────────────────╮            │
│ │ Commands                                                                         │            │
│ ├──────────────────────────────────────────────────────────────────────────────────┤            │
│ │ 0  MoveCall:                                                                     │            │
│ │  ┌                                                                               │            │
│ │  │ Function:  sender                                                             │            │
│ │  │ Module:    tx_context                                                         │            │
│ │  │ Package:   0x0000000000000000000000000000000000000000000000000000000000000002 │            │
│ │  └                                                                               │            │
│ │                                                                                  │            │
│ │ 1  MoveCall:                                                                     │            │
│ │  ┌                                                                               │            │
│ │  │ Function:  transfer_coin                                                      │            │
│ │  │ Module:    shared_coins                                                       │            │
│ │  │ Package:   0x9f6a4c3b71ada16ada9acea1cd35cb245caec0eb28a6de86bb8b6bd3e8f62197 │            │
│ │  │ Arguments:                                                                    │            │
│ │  │   Input  0                                                                    │            │
│ │  │   Result 0                                                                    │            │
│ │  └                                                                               │            │
│ ╰──────────────────────────────────────────────────────────────────────────────────╯            │
│                                                                                                 │
│ Signatures:                                                                                     │
│    F39k4vN55ZucjYiXcw/r4l6a+i8u0YfCeBFXywruFzsSAVlMJ/SCXxdCxh+S4NmSA8jSqykvEwNrkgnwd15RAA==     │
│                                                                                                 │
╰─────────────────────────────────────────────────────────────────────────────────────────────────╯
╭───────────────────────────────────────────────────────────────────────────────────────────────────╮
│ Transaction Effects                                                                               │
├───────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Digest: 6nQ7pwn2vwU296AnrNAkgRZsnht4gTcrTnFKfPVer1y4                                              │
│ Status: Success                                                                                   │
│ Executed Epoch: 52                                                                                │
│ Mutated Objects:                                                                                  │
│  ┌──                                                                                              │
│  │ ID: 0x003ff7f0e4940d94e56729949db16875806aa4b5bc816469ce7c76da2744f3a3                         │
│  │ Owner: Account Address ( 0x111111111504e9350e635d65cd38ccd2c029434c6a3a480d8947a9ba6a15b215 )  │
│  │ Version: 6809041                                                                               │
│  │ Digest: 5uHH1tyf9MjqdJmAaVn2xFuTafGhpusTWJVa6cKyRZrB                                           │
│  └──                                                                                              │
│  ┌──                                                                                              │
│  │ ID: 0xb1b2c1f2f2e33943e8fe7954fca9da40b56cd33cf89c00ac1a45f7a1b028ec11                         │
│  │ Owner: Shared( 6809031 )                                                                       │
│  │ Version: 6809041                                                                               │
│  │ Digest: 29hDC9fzh16WxRTSBje846LUnTQesiTtuM2BWBxzFejP                                           │
│  └──                                                                                              │
│ Shared Objects:                                                                                   │
│  ┌──                                                                                              │
│  │ ID: 0xb1b2c1f2f2e33943e8fe7954fca9da40b56cd33cf89c00ac1a45f7a1b028ec11                         │
│  │ Version: 6809040                                                                               │
│  │ Digest: 8pvLhrQkqmU5K4a4F4Sh4SZ3EAPneZFdo2sfEkqLb6MH                                           │
│  └──                                                                                              │
│ Unwrapped Objects:                                                                                │
│  ┌──                                                                                              │
│  │ ID: 0x8cc24363088cfc0f7e0320456f1c2e0ace7f52ae57e9b893b8fb00a87f5ebaef                         │
│  │ Owner: Account Address ( 0x111111111504e9350e635d65cd38ccd2c029434c6a3a480d8947a9ba6a15b215 )  │
│  │ Version: 6809041                                                                               │
│  │ Digest: 8DVipYhwvBm87wfdrYLN5cjQ9JiumhySnvXP9Kydvc8F                                           │
│  └──                                                                                              │
│ Gas Object:                                                                                       │
│  ┌──                                                                                              │
│  │ ID: 0x003ff7f0e4940d94e56729949db16875806aa4b5bc816469ce7c76da2744f3a3                         │
│  │ Owner: Account Address ( 0x111111111504e9350e635d65cd38ccd2c029434c6a3a480d8947a9ba6a15b215 )  │
│  │ Version: 6809041                                                                               │
│  │ Digest: 5uHH1tyf9MjqdJmAaVn2xFuTafGhpusTWJVa6cKyRZrB                                           │
│  └──                                                                                              │
│ Gas Cost Summary:                                                                                 │
│    Storage Cost: 3328800 NANOS                                                                    │
│    Computation Cost: 1000000 NANOS                                                                │
│    Storage Rebate: 2652400 NANOS                                                                  │
│    Non-refundable Storage Fee: 0 NANOS                                                            │
│                                                                                                   │
│ Transaction Dependencies:                                                                         │
│    3VS6qqfdFT1FkjisGWYqUt6ZuRPRGUr1V26PmZZEG3G4                                                   │
│    63X49x2QuuYNduExZWoJjfXut3s3WDWZ7Tr7nXJu32ZT                                                   │
│    9dEo9n5Ue2PJ545rdE1gRHNjnamzBZfvMxtCDuNqLGeA                                                   │
╰───────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─────────────────────────────╮
│ No transaction block events │
╰─────────────────────────────╯

╭───────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ Object Changes                                                                                                │
├───────────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Mutated Objects:                                                                                              │
│  ┌──                                                                                                          │
│  │ ObjectID: 0x003ff7f0e4940d94e56729949db16875806aa4b5bc816469ce7c76da2744f3a3                               │
│  │ Sender: 0x111111111504e9350e635d65cd38ccd2c029434c6a3a480d8947a9ba6a15b215                                 │
│  │ Owner: Account Address ( 0x111111111504e9350e635d65cd38ccd2c029434c6a3a480d8947a9ba6a15b215 )              │
│  │ ObjectType: 0x2::coin::Coin<0x2::iota::IOTA>                                                               │
│  │ Version: 6809041                                                                                           │
│  │ Digest: 5uHH1tyf9MjqdJmAaVn2xFuTafGhpusTWJVa6cKyRZrB                                                       │
│  └──                                                                                                          │
│  ┌──                                                                                                          │
│  │ ObjectID: 0xb1b2c1f2f2e33943e8fe7954fca9da40b56cd33cf89c00ac1a45f7a1b028ec11                               │
│  │ Sender: 0x111111111504e9350e635d65cd38ccd2c029434c6a3a480d8947a9ba6a15b215                                 │
│  │ Owner: Shared( 6809031 )                                                                                   │
│  │ ObjectType: 0x9f6a4c3b71ada16ada9acea1cd35cb245caec0eb28a6de86bb8b6bd3e8f62197::shared_coins::SharedCoins  │
│  │ Version: 6809041                                                                                           │
│  │ Digest: 29hDC9fzh16WxRTSBje846LUnTQesiTtuM2BWBxzFejP                                                       │
│  └──                                                                                                          │
╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭───────────────────────────────────────────────────────────────────────────────────────────────────╮
│ Balance Changes                                                                                   │
├───────────────────────────────────────────────────────────────────────────────────────────────────┤
│  ┌──                                                                                              │
│  │ Owner: Account Address ( 0x111111111504e9350e635d65cd38ccd2c029434c6a3a480d8947a9ba6a15b215 )  │
│  │ CoinType: 0x2::iota::IOTA                                                                      │
│  │ Amount: 99998323600                                                                            │
│  └──                                                                                              │
╰───────────────────────────────────────────────────────────────────────────────────────────────────╯

Steps To reproduce the bug

Open https://explorer.rebased.iota.org/txblock/6nQ7pwn2vwU296AnrNAkgRZsnht4gTcrTnFKfPVer1y4
Or to create a new transaction like this, run the following CLI commands in the testnet:

# Send a coin to the SharedCoins address:
iota client ptb \
--split-coins gas "[1000000000]" \
--assign new_coins \
--transfer-objects "[new_coins]" @0xb1b2c1f2f2e33943e8fe7954fca9da40b56cd33cf89c00ac1a45f7a1b028ec11 \
--gas-budget 10000000

# Deposit the coin to the SharedCoins object:
COIN_ID=$(iota client gas 0xb1b2c1f2f2e33943e8fe7954fca9da40b56cd33cf89c00ac1a45f7a1b028ec11 --json | jq -r '.[0].gasCoinId')
iota client ptb \
--move-call 0x9f6a4c3b71ada16ada9acea1cd35cb245caec0eb28a6de86bb8b6bd3e8f62197::shared_coins::deposit_coin @0xb1b2c1f2f2e33943e8fe7954fca9da40b56cd33cf89c00ac1a45f7a1b028ec11 @$COIN_ID \
--gas-budget 10000000

# Transfer a coin from the SharedCoins object to the sender:
iota client ptb \
--move-call iota::tx_context::sender \
--assign sender \
--move-call 0x9f6a4c3b71ada16ada9acea1cd35cb245caec0eb28a6de86bb8b6bd3e8f62197::shared_coins::transfer_coin @0xb1b2c1f2f2e33943e8fe7954fca9da40b56cd33cf89c00ac1a45f7a1b028ec11 sender \
--gas-budget 10000000

The last tx will do the unwrapping

Expected behaviour

This unwrapped object: https://explorer.rebased.iota.org/object/0x8cc24363088cfc0f7e0320456f1c2e0ace7f52ae57e9b893b8fb00a87f5ebaef
should be displayed in the summary

Actual behaviour

The object isn't visible

Errors

@Thoralf-M Thoralf-M added the explorer Issues related to the Explorer label Jan 9, 2025
@Khaliddave

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
explorer Issues related to the Explorer
Projects
None yet
Development

No branches or pull requests

2 participants