chart/app
Chris Amow 3222ce03f4 Add a diagnostic mode that reports chart geometry to the server
Chart geometry bugs live in the browser, and the browser is usually on a
different machine from whoever is debugging it — so "it passes in my headless
run" keeps being said about a chart that is unusable on someone's screen. This
session spent hours on that gap: a screenshot showed the crosshair reading 22:42
while the snap label read 22:58, sixteen bars apart on a 1m chart, and no
headless run reproduced it at any viewport, any device pixel ratio, before or
after a resize, or across ten scripted gestures.

Opening the chart with ?diag=1 makes every snap post what the client computed —
the cursor's time, price and x, the snapped time and price, how many bars are
held, the first and last of them, and the chart width — which the server logs as
SNAPDBG. ?diag=0 turns it off; the setting is remembered. Throttled to about one
report a second, and off by default, so it costs nothing when unused.

Kept as a permanent facility rather than scaffolding to delete: this will not be
the last geometry puzzle, and the endpoint takes whatever fields SnapReport
declares. Documented in AGENTS.md alongside the note about where things run.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-10 23:19:42 -05:00
..
analysis Fix trendline anchors jumping away from where they were drawn 2026-08-10 15:18:40 -05:00
api Add a diagnostic mode that reports chart geometry to the server 2026-08-10 23:19:42 -05:00
bars Stop a zero-price tick and a late exchange bar corrupting the store 2026-08-10 17:10:24 -05:00
market Stop a zero-price tick and a late exchange bar corrupting the store 2026-08-10 17:10:24 -05:00
notify Implement M4 confluence alerts 2026-08-09 20:51:32 -05:00
__init__.py Implement M0 Yahoo market data and replay 2026-08-09 20:36:13 -05:00
config.py Update higher timeframes from ticks, and count volume-only trades 2026-08-10 12:07:52 -05:00
runtime.py Update higher timeframes from ticks, and count volume-only trades 2026-08-10 12:07:52 -05:00