feat: add tx-log middleware#635
Merged
kien6034 merged 19 commits intoclassic-terra:mainfrom Jan 15, 2026
Merged
Conversation
ab2384d to
95a5d55
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds a middleware to reconstruct the deprecated logs field in transaction query responses for backwards compatibility with Cosmos SDK 0.50+, along with CI/CD optimizations and test improvements.
Changes:
- Added
TxLogsMiddlewareto reconstruct the deprecatedlogsfield fromeventsin transaction query responses for backwards compatibility - Optimized E2E CI workflow with Docker layer caching and parallel test execution
- Fixed test timing issues by querying balances immediately before transactions to minimize interference from staking rewards
Reviewed changes
Copilot reviewed 7 out of 8 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| server/tx_logs_middleware.go | New middleware implementation that intercepts tx query responses and reconstructs logs field from events |
| server/tx_logs_middleware_test.go | Comprehensive unit tests for the middleware including multiple test scenarios |
| app/app.go | Integration of TxLogsMiddleware into the API server router |
| tests/e2e/api_regression_test.go | New E2E test validating the logs reconstruction functionality |
| tests/e2e/e2e_test.go | Timing fixes to query balances closer to transactions to reduce test flakiness |
| tests/e2e/e2e.Dockerfile | Docker build optimization with pre-cached Go modules from host |
| .github/workflows/e2e.yml | Complete workflow refactor with build/test separation, parallel execution, and caching |
| .gitignore | Added .cache/ directory for CI-populated Go module cache |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
StrathCole
reviewed
Jan 15, 2026
Collaborator
StrathCole
left a comment
There was a problem hiding this comment.
Looks good, just want to clarify that one question.
StrathCole
approved these changes
Jan 15, 2026
kien6034
approved these changes
Jan 15, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary of changes
Report of required housekeeping
(FOR ADMIN) Before merging