-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Tracer doesn't detect out-of-gas errors #3394
Comments
hmmmm... Investigating this it seems that the issue is only for out of gas errors from very early protocol versions. Testing locally against Will continue to investigate a potential resolution here but the issue does not seem to be present on current API. Example of an out of gas error that is picked up by debug tracer from a recent tx:
Response:
|
(hopefully) fixes #3394 See the issue for the context. Looks like some old transactions do not have error stored for out-of-gas errors. However, we know that they're failed, and we know that based on [the error field from the transactions table](https://github.com/matter-labs/zksync-era/blob/main/core/lib/dal/src/models/storage_transaction.rs#L361). This PR adds a "fallback" error -- if no other error is detected in the call trace, we use the error from the sequencer. Granted, I do not have access to the mainnet DB, so not sure what error messages are inside, but if I am to guess, it will be more or less adequate. 😅⚠️ To make things spicier, I have no way to test this functionality (per @dutterbutter report in the issue, it does not reproduce with the current protocol version), so it's kind of "hope it helps" fix. Please be careful during the review.
🐛 Bug Report
📝 Description
When making
debug_traceBlockByNumber
RPC request for transactions that failed with out-of-gas error response would not include anything in theerror
field.🔄 Reproduction Steps
Example transactions:
Block 2558830 -> Tx: 0x1d55f591f2dec2db4ede9dfdf1e921c38f315daeddfc5f4f690ab13c1fa0cc72 (example listed above)
Block 2637427 -> Tx: 0xacb4bb951661950a9cb0df04f3e5ce8dce37c98a684924a07e1bab5f118202c8
Block 2610752 -> Tx: 0x38822e3ef0298e9131790333356986d5051784861e43e602da5a9b97b8c66118
Block 2579103 -> Tx: 0x45634aa7756181707f1b8e6ef6404069c4f2c4506f20466ed637850a113237ab
Block 2642447 -> Tx: 0x94fc982c4c2fb8146912f15a362bb5292e8094a77ec68c6be243e5861cec2321
🤔 Expected Behavior
error
field includes error message😯 Current Behavior
In the response
error
field would benull
.🖥️ Environment
Mainnet
📋 Additional Context
Github Discussion report - zkSync-Community-Hub/zksync-developers#836
📎 Log Output
The text was updated successfully, but these errors were encountered: