Skip to content
This repository has been archived by the owner on Apr 4, 2024. It is now read-only.

Fix TxIndex wrongly when trace first Tx of a block (backport #1187) #1195

Merged
merged 2 commits into from
Jul 20, 2022

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Jul 20, 2022

This is an automatic backport of pull request #1187 done by Mergify.
Cherry-pick of cd41c48 has failed:

On branch mergify/bp/release/v0.17.x/pr-1187
Your branch is up to date with 'origin/release/v0.17.x'.

You are currently cherry-picking commit cd41c48.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   x/evm/keeper/grpc_query.go

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   CHANGELOG.md

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/github/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally


Mergify commands and options

More conditions and actions can be found in the documentation.

You can also trigger Mergify actions by commenting on this pull request:

  • @Mergifyio refresh will re-evaluate the rules
  • @Mergifyio rebase will rebase this PR on its base branch
  • @Mergifyio update will merge the base branch into this PR
  • @Mergifyio backport <destination> will backport this PR on <destination> branch

Additionally, on Mergify dashboard you can:

  • look at your merge queues
  • generate the Mergify configuration with the config editor.

Finally, you can contact us on https://mergify.com

…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
@codecov
Copy link

codecov bot commented Jul 20, 2022

Codecov Report

Merging #1195 (265feee) into release/v0.17.x (f740e13) will increase coverage by 0.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@                 Coverage Diff                 @@
##           release/v0.17.x    #1195      +/-   ##
===================================================
+ Coverage            61.80%   61.81%   +0.01%     
===================================================
  Files                   90       90              
  Lines                 7320     7322       +2     
===================================================
+ Hits                  4524     4526       +2     
  Misses                2573     2573              
  Partials               223      223              
Impacted Files Coverage Δ
x/evm/keeper/grpc_query.go 69.38% <100.00%> (+0.13%) ⬆️

@fedekunze fedekunze merged commit 6c47503 into release/v0.17.x Jul 20, 2022
@fedekunze fedekunze deleted the mergify/bp/release/v0.17.x/pr-1187 branch July 20, 2022 15:53
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>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants