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

feat: add txpool namespace RPC methods #146

Merged
merged 9 commits into from
Jun 21, 2021

Conversation

crypto-facs
Copy link
Contributor

Closes: #124

Description

Enabled txpool namespace with txpool_content method that complies with the go ethereum documentation. The decision was to return an empty response (this is explained in further detail in the issue). Endpoint is needed to unblock block explorer integration

NOTE: Did not update documentation as the method is not fully functional yet. Happy to do it if it is required.


For contributor use:

  • Targeted PR against correct branch (see CONTRIBUTING.md)
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Code follows the module structure standards.
  • Wrote unit and integration tests
  • Updated relevant documentation (docs/) or specification (x/<module>/spec/)
  • Added relevant godoc comments.
  • Added a relevant changelog entry to the Unreleased section in CHANGELOG.md
  • Re-reviewed Files changed in the Github PR explorer

For admin use:

  • Added appropriate labels to PR (ex. WIP, R4R, docs, etc)
  • Reviewers assigned
  • Squashed all commits, uses message "Merge pull request #XYZ: [title]" (coding standards)

Copy link
Contributor

@fedekunze fedekunze left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Can you also add the txpool_inspect and txpool_status endpoints to return empty values? See https://geth.ethereum.org/docs/rpc/ns-txpool

ethereum/rpc/txpool_api.go Show resolved Hide resolved
ethereum/rpc/txpool_api.go Outdated Show resolved Hide resolved
@crypto-facs
Copy link
Contributor Author

Hey @fedekunze thanks for the review! Just added the other two endpoints with a similar approach. Feel free to give it a final look!

@crypto-facs crypto-facs changed the title feat: add txpool namespace and txpool_content RPC method feat: add txpool namespace RPC methods Jun 20, 2021
Copy link
Contributor

@fedekunze fedekunze left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK. Can you also add a description on de CHANGELOG.md with the issue number and description under the Unreleased > Improvements section?

ethereum/rpc/backend.go Outdated Show resolved Hide resolved
@fedekunze
Copy link
Contributor

fedekunze commented Jun 21, 2021

follow up issue, add tests for RPC and documentation of the RPC endpoint

@codecov
Copy link

codecov bot commented Jun 21, 2021

Codecov Report

Merging #146 (acd394f) into main (6be18a1) will increase coverage by 0.85%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #146      +/-   ##
==========================================
+ Coverage   68.81%   69.67%   +0.85%     
==========================================
  Files           5        5              
  Lines         635      643       +8     
==========================================
+ Hits          437      448      +11     
+ Misses        183      179       -4     
- Partials       15       16       +1     
Impacted Files Coverage Δ
app/ante/eth.go 88.54% <0.00%> (-0.55%) ⬇️
app/ante/ante.go 46.37% <0.00%> (+8.14%) ⬆️

@fedekunze fedekunze merged commit b4d3659 into evmos:main Jun 21, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement txpool JSON-RPC namespace
2 participants