Skip to content

Commit

Permalink
Rephrase log when committed TX not in local mempool + make it debug (#…
Browse files Browse the repository at this point in the history
…738) (#749)

Closes #737

If the execution hits the log line changed in this PR, it doesn't mean there is an error condition.
A TX included in a block does not need to be present in the local mempool of a nodes at the time it is processing the new block.
As the info is still useful, we re-word the message and turn it into a Debug log

---

#### PR checklist

- [ ] Tests written/updated
- [ ] Changelog entry added in `.changelog` (we use [unclog](https://github.com/informalsystems/unclog) to manage our changelog)
- [ ] Updated relevant documentation (`docs/` or `spec/`) and code comments

(cherry picked from commit 6498d67)

Co-authored-by: Sergio Mena <sergio@informal.systems>
  • Loading branch information
mergify[bot] and sergio-mena committed Apr 24, 2023
1 parent 3b7c719 commit 883c846
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion mempool/clist_mempool.go
Original file line number Diff line number Diff line change
Expand Up @@ -612,7 +612,9 @@ func (mem *CListMempool) Update(
// 100
// https://github.com/tendermint/tendermint/issues/3322.
if err := mem.RemoveTxByKey(tx.Key()); err != nil {
mem.logger.Error("Committed transaction could not be removed from mempool", "key", tx.Key(), err.Error())
mem.logger.Debug("Committed transaction not in local mempool (not an error)",
"key", tx.Key(),
"error", err.Error())
}
}

Expand Down

0 comments on commit 883c846

Please sign in to comment.