ChildNotFound and failed to decode log problems

Hi everyone,

We’ve just launched a new matching engine, and we’re encountering some errors intermittently during the matching process. Can anyone help me figure out how to fix these issues?

ChildNotFound

Response errors; Transaction(0x7f63db2a4947c3f729176061fa8c69e5d7d171e4a9226f4821367708011054e4) execution error: "Storage error: ChildError(ChildNotFound([42, 135, 196, 191, 45, 199, 203, 143, 231, 34, 100, 15, 143, 47, 126, 123, 115, 8, 220, 255, 109, 182, 155, 243, 117, 241, 110, 225, 187, 110, 242, 93]))"`

failed to decode log from require revert

failed to decode log from require revert: discriminant 2 doesn't point to any variant: [("InvalidAmount", Unit), ("InvalidArrayLength", Unit)], receipts: (Call ( id: 00000000000000000000000000000000000000000000000000000000000 0, to: 08ca18ed558d6229f001641d43aac58e00f9eb7e25c9bea6d33716af61043b2a, amount: 0, asset_id: f8f8b6283d7fa5b672b530cbb84fcccb4ff8dc40f8176ef4544ddb1f1952ad07, gas: 4957, param1: 10488, param2: 10504, pc: 11688, is: 11688 ), LogData id: 08ca18ed550d6229f081641d43aac58e00f9eb7e25c9bea6d33716af61e43b2a, ra:0, rb: 4038555509566971562, ptr: 67107848, len: 8, digest: cd0424754498806db5a13c5f371f1f04ff6d2470f24a89bd886548e5dce77f70, pc: 68040, is: 11688, data: Some(00000000000eee2) J, Revert ( id: 08ca18ed550d6229f001641d43aac58e0819eb7e25c9bea6d33716af61e43b2a, ra:18446744073709486880, pc: 68848, is: 11688 ), ScriptResult ( result: Revert, gas_used: 37444 11

Rust SDK version

fuels = { version = "0.64", features = ["fuel-core-lib"] }

Fuelup show

Default host: aarch64-apple-darwin
fuelup home: /Users/alexey/.fuelup

installed toolchains
--------------------
devnet-aarch64-apple-darwin
latest-aarch64-apple-darwin
nightly-aarch64-apple-darwin
nightly-2024-05-31-aarch64-apple-darwin
nightly-2024-06-03-aarch64-apple-darwin
nightly-2024-06-14-aarch64-apple-darwin
nightly-2024-06-19-aarch64-apple-darwin (override)
testnet-aarch64-apple-darwin (default)

active toolchain
----------------
nightly-2024-06-19-aarch64-apple-darwin (override), path: /Users/alexey/Desktop/orderbook-contract/fuel-toolchain.toml
  forc : 0.60.0+nightly.20240619.e30497caaa
    - forc-client
      - forc-deploy : not found
      - forc-run : not found
    - forc-crypto : not found
    - forc-debug : not found
    - forc-doc : not found
    - forc-explore : 0.28.1+nightly.20240619.4bb7392eed
    - forc-fmt : not found
    - forc-lsp : not found
    - forc-tx : not found
    - forc-wallet : 0.8.0+nightly.20240619.d8bb6ed3e1
  fuel-core : 0.30.0+nightly.20240619.12cb17f505
  fuel-core-keygen : not found

Hey @fuel ,

Can you provide the link to the codebase and / or the exact code which is causing this in Rust?

Thanks for posting the fuelup show results this time :slight_smile:

1 Like

Sure, here I calling our sdk

and here is the method from the SDK

Thank you

Hi @fuel ,

Thanks for posting the code, I’ll see that the Rust SDK team can take a look and see if this is on our side with decoding.

The SDK is unable to find the definition of the 3rd variant of an enum in the abi file.
Could it be that you’ve made some changes to the contract but didn’t update the abi file provided to the SDK?
You can also check whether the abi file mentions all the enum variants. Look for the enum that contains InvalidAmount and InvalidArrayLength and check if there is a third one.

1 Like

We fixed all of the errors except for ChildNotFound, can you suggest what we can do to eliminate this error?

@fuel is this issue resolved?