Skip to content

Add tests + Dockerfile change - #1

Merged
0xcompose merged 2 commits into
mainfrom
add-tests
Aug 10, 2026
Merged

Add tests + Dockerfile change#1
0xcompose merged 2 commits into
mainfrom
add-tests

Conversation

@0xcompose

Copy link
Copy Markdown
Owner

No description provided.

0xcompose and others added 2 commits August 10, 2026 13:47
Covers the logic that has been changing under load: parsing both wire shapes
(infra brotli diffs and RPC eth_subscribe, including providers that stream
cumulative block snapshots), the writer's source labelling and inter-process
lock, and the latency comparison join.

tests/test_e2e.py drives the real recorder loop against a local websocket
server with canned frames, asserting the decoded output. It needs no network,
so it is deterministic and fast enough to gate CI: subscribe handshake,
reconnect after a drop, and junk frames not killing the stream.

Verified the suite fails on three deliberate mutations (skipping snapshot
de-duplication, dropping the subscribe frame, removing the flock), so the
green run means something.

Also ignore recordings (*.bin, latency-compare-*/, remote-data/) -- the
capture directories are ~400MB and were one `git add .` away from the repo.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
A source-only change re-ran the whole install, re-downloading every dependency:
14s of a 20s build spent fetching wheels that had not changed.

Mount pip's cache directory so reinstalls come from local wheels instead of the
network. Rebuild after a code change drops to 7s; cold build is unchanged.

Reordering COPY and RUN to get a separate dependency layer would be marginally
faster (4s), but `pip install .` needs the source tree present to build the
wheel -- with only pyproject.toml copied, setuptools finds no packages and
installs an empty one, producing a green build whose entrypoint dies on
ModuleNotFoundError. Avoiding that means either duplicating the dependency list
or parsing it out of pyproject, and neither is worth three seconds.

Needs BuildKit, default since Docker 23; no syntax directive required.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@0xcompose
0xcompose merged commit 06b5617 into main Aug 10, 2026
1 check passed
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

Successfully merging this pull request may close these issues.

1 participant