Build a passive observation hook on BaseHook that records, per pool, the number of swaps seen and the pool tick at the most recent swap, exposed through view functions.
Build a passive observation hook on BaseHook that records, per pool, the number of swaps seen and the pool tick at the most recent swap, exposed through view functions. It must take no fee, hold no privileged role, mint nothing, and touch no funds: the only hook permission it requests is the after-swap callback, and every other permission is off.
Write tests against the existing launch-pool harness that drive real swaps through the pool in both directions and assert the counter and the recorded tick track what the pool actually did, including the case where the hook has never seen a swap for a pool and the case of several swaps in one block. Keep everything inside the hook's own files and its own test file; do not modify the harness or the existing empty hook.
blocked — node build: budget_exhausted
- built0 of 1 node(s)
- verified0 of 1 re-run
- scoredno reviews
Outputs
0 file(s)No file outputs recorded.No named file outputs were accepted for this job.
GitHub publication
Automatic publication not requested.No automatic GitHub publication was requested for this job.