Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support block tags in getLogs() #532

Merged
merged 2 commits into from
Sep 19, 2022

Conversation

dimitrovmaksim
Copy link
Collaborator

Signed-off-by: Maksim Dimitrov [email protected]

Description:

  1. Fixes getLogs not being able to handle block tags (latest, earliest)
  2. Adds block range limit (default 500). Can be configured with by setting ETH_GET_LOGS_BLOCK_RANGE_LIMIT env variable

Related issue(s):

Fixes #472

Notes for reviewer:

Maybe we should set a max block range limit?

Checklist

  • Documented (Code comments, README, etc.)
  • Tested (unit, integration, etc.)

Signed-off-by: Maksim Dimitrov <[email protected]>
Signed-off-by: Maksim Dimitrov <[email protected]>
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@codecov-commenter
Copy link

Codecov Report

Base: 76.67% // Head: 76.88% // Increases project coverage by +0.20% 🎉

Coverage data is based on head (8a992cd) compared to base (bed9aa9).
Patch coverage: 80.00% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #532      +/-   ##
==========================================
+ Coverage   76.67%   76.88%   +0.20%     
==========================================
  Files          12       12              
  Lines         926      943      +17     
  Branches      145      149       +4     
==========================================
+ Hits          710      725      +15     
- Misses        164      169       +5     
+ Partials       52       49       -3     
Impacted Files Coverage Δ
packages/relay/src/lib/eth.ts 84.71% <76.66%> (+0.06%) ⬆️
packages/relay/src/lib/clients/mirrorNodeClient.ts 90.14% <100.00%> (ø)
packages/relay/src/lib/constants.ts 100.00% <100.00%> (ø)
packages/relay/src/lib/errors/JsonRpcError.ts 77.77% <100.00%> (+2.77%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Collaborator

@Nana-EC Nana-EC left a comment

Choose a reason for hiding this comment

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

LG

@Nana-EC Nana-EC added bug Something isn't working limechain P1 labels Sep 19, 2022
@Nana-EC Nana-EC added this to the 0.8.0 milestone Sep 19, 2022
@dimitrovmaksim dimitrovmaksim merged commit 17ef734 into main Sep 19, 2022
@dimitrovmaksim dimitrovmaksim deleted the 472-get-logs-add-support-for-block-tags branch September 19, 2022 15:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working limechain P1
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

eth_getLogs not handling non int block params
3 participants