Closed PatrickAlphaC closed 7 months ago
@mattsse The CREATE failure reason coming from revm is InvalidOperandOOG
, will look into when it might happen, but wondering if you might have a guess?
@PatrickAlphaC "0x60a88060093d393df3602035335f540114156100a457"
is interpreted as a string
to save hex bytes to bytecode
, change it to bytecode = hex"60a88060093d393df3602035335f540114156100a457";
on my machine this change fixes the issue
That solved it!
Closed... but I'm wondering if I should have?
@PatrickAlphaC Seeing this the past few days when running some calls against Telos, thanks for reporting.
@PatrickAlphaC Seeing this the past few days when running some calls against Telos, thanks for reporting.
Same here while using foundry with telos. Happening with both test and script. You found any solution?
@derekbar90 @prajwalghate could you please provide a repro we could use?
hex
Hey @klkvr I created a repo solely to check if the problem persist. Getting the InvalidOperandOOG error.
Here is the repo telos-foundry-repo
Running this command
forge script script/PendingRewards.s.sol:PendingRewards --rpc-url https://mainnet.telos.net/evm -vvvv
Hey, @klkvr any update on this, I tried from my side still couldn't figure out what is wrong
tbh those network RPCs were behaving very weird when I was trying to test your repro :/ so not sure what is wrong exactly
maybe related https://x.com/pcaversaccio/status/1799053406792974822?s=46&t=4P6kq9daicxFwv9BbZasAA
tbh those network RPCs were behaving very weird when I was trying to test your repro :/ so not sure what is wrong exactly
maybe related https://x.com/pcaversaccio/status/1799053406792974822?s=46&t=4P6kq9daicxFwv9BbZasAA
Yes, you were right it is related to rpc. This old rpc https://rpc3.telos.net/evm solved the issue. Thanks.
I met same issue, change it to: bytecode = hex"60a88060093d393df3602035335f540114156100a457"; as a hex string, fixes the issue.
Component
Forge
Have you ensured that all of these are up to date?
What version of Foundry are you on?
forge 0.2.0 (1a4960d 2024-03-20T00:28:07.727577000Z)
What command(s) is the bug in?
forge script
Operating System
macOS (Intel)
Describe the bug
Deploying certain bytecodes fail for foundry, or cause foundry to get confused.
The following
This should deploy the
0x60a88060093d393df3602035335f540114156100a457
bytecode on chain, however, running:We get the following output:
I am able to deploy this contract to sepolia, no problem:
And I have done so here:
https://sepolia.etherscan.io/tx/0x98469582507a99a166bdb1ca58f3073fa4f5eb26bc5e3552571821b8e106b371
I ran into this as foundry was having a hard time running a test in
--debug
mode, where it kept crashing and not being able to read the opcodes on certain contracts. I'm not sure what that's about.