Whole file
joeynyc/hermes-hud
The author described this change as “fix: read current Hermes session model column”. It counts as a record because the check below fails on the code as it stood at 541bfe7cb and passes on 9352d04cc, with nothing else changed between the two runs.
Projectjoeynyc/hermes-hud
Fix saved2026-05-08
Sharing licenceMIT · LICENSE
Change size+3 −3
What the code was meant to do, written into the code itself as a save note
fix: read current Hermes session model column
The change
| 60 | 60 | message_count, tool_call_count, | |
| 61 | 61 | input_tokens, output_tokens, | |
| 62 | 62 | cache_read_tokens, cache_write_tokens, | |
| 63 | - | reasoning_tokens, estimated_cost_usd, model_config | |
| 63 | + | reasoning_tokens, estimated_cost_usd, model, model_config | |
| 64 | 64 | FROM sessions | |
| 65 | 65 | ORDER BY started_at DESC | |
| 66 | 66 | """) | |
| ⋯ | |||
| 73 | 73 | ended = datetime.fromtimestamp(ended_raw) if ended_raw else None | |
| 74 | 74 | ||
| 75 | 75 | # Try to extract model from model_config JSON | |
| 76 | - | model = None | |
| 76 | + | model = safe_get(row, "model") | |
| 77 | 77 | mc_raw = safe_get(row, "model_config") | |
| 78 | - | if mc_raw: | |
| 78 | + | if not model and mc_raw: | |
| 79 | 79 | try: | |
| 80 | 80 | mc = json.loads(mc_raw) | |
| 81 | 81 | model = mc.get("model") or mc.get("default") | |
The check that tells the two apart
fail→pass·tests/test_collectors.py::TestSessionsCollector::test_session_model_uses_schema_column
Check file tests/test_collectors.py, taken without changes from the fix and copied onto the older code, so the exact same check runs against both versions.
Origin and history
The code before it541bfe7cb7dcbe1a355eaeafd136ad35d27e0f1d
Broken version dated2026-04-17
Modulehermes_hud.collectors.sessions
Units changedcollect_sessions
Fingerprintdee728eb7540c326
Checked2026-08-18 by goldset/0.1
Every field above is generated by our program. None of it is written by hand.