AcalaNetwork / chopsticks

Create parallel reality of your Substrate network.
Apache License 2.0
133 stars 80 forks source link

`Host function not implemented` when forking v1.11 chain. #754

Closed metricaez closed 4 months ago

metricaez commented 4 months ago

We are currently facing an issue when forking a chain that is at v1.11 with the following log:

[12:09:46.874] INFO (block-builder): Failed to apply extrinsic {} Error: Host function not implemented: ext_storage_proof_size_storage_proof_size_version_1
    app: "chopsticks"

We have encountered a similar issue in the past in our own implementation when upgrading from v1.8 to v1.9 as a new node function is implemented from that version and forward as shown here.

xlc commented 4 months ago

it needs to be implemented on smoldot first

xlc commented 4 months ago

can you provide a wasm and config file so we can later check if the implementation works?

metricaez commented 4 months ago

hey! unfortunately I cannot provide the current rpc we are trying with but I have built a lean version that has no business logic of the runtime that I can share with you and still reproduces the error. Please let me know what do exactly would you need me to share with you. thanks

xlc commented 4 months ago

you can upload a wasm and config file here that can repreoduce this issue also give https://github.com/AcalaNetwork/chopsticks/pull/755 a try to see if it fixes the issue

metricaez commented 4 months ago

Hi, I have built and tested #755 and it does fix the issue, thanks!

On the other hand, I am curious and a little bit confused about the wasm request since the issue comes from the node impl and not the runtime itself. Could you please elaborate ?

xlc commented 4 months ago

issue is always coming from wasm because that’s the only thing chopsticks is testing for this particular case, the wasm is using a new host function that wasn’t implemented by smoldot so I requested smoldot to implement it and have chopsticks updated to include the new host function

xlc commented 4 months ago

should be fixed by #755