-
Notifications
You must be signed in to change notification settings - Fork 88
fix: fixes debug_traceBlockByNumber response to not be null for a transaction with no internal calls #4440
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
fix: fixes debug_traceBlockByNumber response to not be null for a transaction with no internal calls #4440
Conversation
Signed-off-by: Simeon Nakov <simeon.nakov@limechain.tech>
Test Results 20 files ±0 265 suites ±0 20m 54s ⏱️ -45s Results for commit 6debd0c. ± Comparison against base commit dcba3d0. This pull request removes 1 test.♻️ This comment has been updated with latest results. |
|
I can't seem to reproduce this issue. Block 0x5067CB1 (mentioned in the associated ticket) contains two {
"result": [
{
"txHash": "0xa74c140aedec484c5c6cb559aecd75386d15cbafcc3e55c90d5302adbea86337",
"result": {
"type": "CALL",
"from": "0x339d413ccefd986b1b3647a9cfa9cbbe70a30749",
"to": "0x3c2269811836af69497e5f486a85d7316753cf62",
"value": "0x0",
"gas": "0xaae60",
"gasUsed": "0x88b80",
"input": "0x3161b7f600000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000016f000000000000000000000000000000000000000000000000000002109014be420000000000000000000000000000000000000000000000000000000005f86e6b0000000000000000000000000000000000000000000000000000000000000010",
"output": "0x",
"calls": [
{
"type": "DELEGATECALL",
"from": "0x3c2269811836af69497e5f486a85d7316753cf62",
"to": "0x4ee2f9b7cf3a68966c370f3eb2c16613d3235245",
"gas": "0xa1b93",
"gasUsed": "0x2a78",
"input": "0x3161b7f600000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000016f000000000000000000000000000000000000000000000000000002109014be420000000000000000000000000000000000000000000000000000000005f86e6b0000000000000000000000000000000000000000000000000000000000000010",
"output": "0x",
"value": "0x0"
}
]
}
}
],
"jsonrpc": "2.0",
"id": 1
}Am I missing something or it's just too late to use that block now? |
|
Couple of questions left on the associated ticket as well #4386 (comment) |
|
@quiet-node hmm, I also can't reproduce it along with other examples I had written down. (perhaps it was a bug on MN side due to modularization, that is now fixed?). Nevertheless, I still think we should fix the response format for this particular case. I will try to find another example. |
Yeah let's bring this up to a parking lot session and discuss as a team |
Signed-off-by: Simeon Nakov <simeon.nakov@limechain.tech>
Signed-off-by: Simeon Nakov <simeon.nakov@limechain.tech>
Signed-off-by: Simeon Nakov <simeon.nakov@limechain.tech>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left some nit comments
Signed-off-by: Simeon Nakov <simeon.nakov@limechain.tech>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #4440 +/- ##
==========================================
- Coverage 96.23% 96.22% -0.01%
==========================================
Files 121 121
Lines 20001 19998 -3
Branches 1756 1751 -5
==========================================
- Hits 19247 19244 -3
Misses 735 735
Partials 19 19
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
Description
Ensures that
debug_traceBlockByNumberanddebug_traceTransactionwithcallTraceralways return acallsfield as an array, nevernullorundefined, even when transactions have no internal calls.Related issue(s)
Fixes #4386
Testing Guide
debug_traceBlockByNumberfor a block that contains a transaction with no calls such as 0x522ba41 on mainnetChanges from original design (optional)
N/A
Additional work needed (optional)
N/A
Checklist