Alternate infrastructure for testing event filters
- Dominant language
- Python
- Stars
- 5.5k
- Forks
- 1.7k
- Avg merge
- 3d 10h
- Merged PRs (30d)
- 2
Description
### What was wrong?
Testing event filters sucks. Either we depend on `eth-tester` which *probably/maybe* implements the filter logic correctly, or we use `geth` which results in flaky tests and the bad kind of black-box testing since when things fail we don't really have any good way to know why...
### How can it be fixed?
I recently wrote this: https://github.com/ethereum/cthaeh
The most relevant parts are:
- The SQLAlchemy ORM models:
- https://github.com/ethereum/cthaeh/blob/a3f63b0522d940af37f485ccbeed07666adb465b/cthaeh/models.py
- The filtering logic:
- https://github.com/ethereum/cthaeh/blob/a3f63b0522d940af37f485ccbeed07666adb465b/cthaeh/filter.py
If we were to extract these two bits plus some other *support* code into something stand-alone that is more like a *library* then we should be able to use this for testing our log filter code.
Contributor guide
Assessment
This issue has not been assessed yet.