This repository has been archived by the owner on Apr 4, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 566
Fix TxIndex wrongly when trace first Tx of a block #1187
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
If `Predecessors` is empty, `txConfig.TxIndex` originally = 0 and when it reachs line 401 `txConfig.TxIndex++`, it will becomes 1. It should be 0
VictorTrustyDev
requested review from
fedekunze,
khoslaventures and
jolube
as code owners
July 17, 2022 07:13
@VictorTrustyDev Nitpick but throw the ++ in an else |
fedekunze
reviewed
Jul 18, 2022
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.
Thanks @VictorTrustyDev, can you add a test and bug fix changelog entry?
@fedekunze well I'm sorry I've tried to look at geth's document but I can't find how to get txIndex as part of response so I have no idea how to write test case for this |
fedekunze
added
the
backport/0.17.x
PR scheduled for inclusion in the v0.17's next stable release
label
Jul 19, 2022
Codecov Report
@@ Coverage Diff @@
## main #1187 +/- ##
==========================================
+ Coverage 62.31% 62.32% +0.01%
==========================================
Files 91 91
Lines 7411 7413 +2
==========================================
+ Hits 4618 4620 +2
Misses 2563 2563
Partials 230 230
|
fedekunze
approved these changes
Jul 20, 2022
mergify bot
pushed a commit
that referenced
this pull request
Jul 20, 2022
…1187) * Fix TxIndex wrongly when trace first Tx of a block If `Predecessors` is empty, `txConfig.TxIndex` originally = 0 and when it reachs line 401 `txConfig.TxIndex++`, it will becomes 1. It should be 0 * apply suggestion and add change-log * fix comment Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com> (cherry picked from commit cd41c48) # Conflicts: # CHANGELOG.md
fedekunze
added a commit
that referenced
this pull request
Jul 20, 2022
…ackport #1187) (#1195) * fix(evm): `TxIndex` is wrong when trace is the first tx of a block (#1187) * Fix TxIndex wrongly when trace first Tx of a block If `Predecessors` is empty, `txConfig.TxIndex` originally = 0 and when it reachs line 401 `txConfig.TxIndex++`, it will becomes 1. It should be 0 * apply suggestion and add change-log * fix comment Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com> (cherry picked from commit cd41c48) # Conflicts: # CHANGELOG.md * fix RPC Co-authored-by: Victor Pham <me@victortrusty.dev> Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
hoanguyenkh
pushed a commit
to AstraProtocol/ethermint
that referenced
this pull request
Jul 27, 2022
…vmos#1187) * Fix TxIndex wrongly when trace first Tx of a block If `Predecessors` is empty, `txConfig.TxIndex` originally = 0 and when it reachs line 401 `txConfig.TxIndex++`, it will becomes 1. It should be 0 * apply suggestion and add change-log * fix comment Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
hoanguyenkh
pushed a commit
to AstraProtocol/ethermint
that referenced
this pull request
Jul 27, 2022
…ackport evmos#1187) (evmos#1195) * fix(evm): `TxIndex` is wrong when trace is the first tx of a block (evmos#1187) * Fix TxIndex wrongly when trace first Tx of a block If `Predecessors` is empty, `txConfig.TxIndex` originally = 0 and when it reachs line 401 `txConfig.TxIndex++`, it will becomes 1. It should be 0 * apply suggestion and add change-log * fix comment Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com> (cherry picked from commit cd41c48) # Conflicts: # CHANGELOG.md * fix RPC Co-authored-by: Victor Pham <me@victortrusty.dev> Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
devon-chain
pushed a commit
to devon-chain/ethermint
that referenced
this pull request
Aug 2, 2022
…vmos#1187) * Fix TxIndex wrongly when trace first Tx of a block If `Predecessors` is empty, `txConfig.TxIndex` originally = 0 and when it reachs line 401 `txConfig.TxIndex++`, it will becomes 1. It should be 0 * apply suggestion and add change-log * fix comment Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
devon-chain
pushed a commit
to PundiAI/ethermint
that referenced
this pull request
Nov 17, 2022
…vmos#1187) * Fix TxIndex wrongly when trace first Tx of a block If `Predecessors` is empty, `txConfig.TxIndex` originally = 0 and when it reachs line 401 `txConfig.TxIndex++`, it will becomes 1. It should be 0 * apply suggestion and add change-log * fix comment Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
If
Predecessors
is empty,txConfig.TxIndex
originally = 0 and when it reachs line 401txConfig.TxIndex++
, it will becomes 1. It should be 0Closes: #XXX
Description
Fix TxIndex wrongly when trace first Tx of a block
For contributor use:
docs/
) or specification (x/<module>/spec/
)godoc
comments.Unreleased
section inCHANGELOG.md
Files changed
in the Github PR explorerFor admin use:
WIP
,R4R
,docs
, etc)