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

Method handler crashed when using getPastLogs API #4982

Closed
JosephK95 opened this issue Aug 10, 2022 · 3 comments
Closed

Method handler crashed when using getPastLogs API #4982

JosephK95 opened this issue Aug 10, 2022 · 3 comments

Comments

@JosephK95
Copy link

Hi all,

When we execute getPastLogs API, it seems that Erigon crashes if the toBlock parameter receives a value larger than MaxUint32.

System information

Erigon version: 2022.07.4-alpha-d88fc824
OS & Version: Ubuntu 20.04.4 LTS
Node.js / web3.js versions: v16.15.0 / v1.7.3

Expected behaviour

Erigon should return an array of log objects or perform error handling.

Actual behaviour

...
[EROR] [08-10|13:13:36.167] RPC method eth_getLogs crashed: rangeEnd-1 > MaxUint32
[service.go:217 panic.go:838 roaring.go:1489 eth_receipts.go:121 value.go:556 value.go:339 service.go:222 handler.go:507 handler.go:412 handler.go:360 handler.go:191 handler.go:284 asm_amd64.s:1571]
[WARN] [08-10|13:13:36.167] Served                                   conn=127.0.0.1:39210 method=eth_getLogs reqid=2 t=116.468µs err="method handler crashed"
...

Steps to reproduce the behaviour

  1. Download the following file and untar it:
    crash.tar.gz
  2. Untar the data-erigon.tar.gz file in the 'crash' directory.
  3. Execute Erigon binary with the following flags:
    erigon --datadir ./crash/data-erigon --http.port 8547 --http --http.api eth --networkid 15 --nodiscover
  4. Execute the test case file: node crash/test1.js
@revitteth
Copy link
Contributor

Closing as fixed in #4968

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@revitteth @JosephK95 and others