Commit Graph
8049 Commits
Author SHA1 Message Date
Rodrigo Gomes 12df57498a fix(sessions): warn once per state.db when 'source' column is missing
Observed: on a multi-profile install where one profile's state.db predates
the agent's `source` column, errors.log gained one identical line every
~15 s (276 lines in ~70 min):

  api.models WARNING agent session listing skipped: state.db at
  /data/hermes/profiles/planner/state.db has no 'source' column (older
  hermes-agent?). Agent sessions unavailable. Upgrade hermes-agent to
  fix this.

Mechanism: api/agent_sessions.py read_importable_agent_session_rows()
runs `PRAGMA table_info(sessions)` and warns unconditionally when the
column is absent (api/agent_sessions.py:564 before this change).
api/models.py get_cli_sessions(all_profiles=True) calls it for every
profile on every sidebar poll, behind only the 5 s
_CLI_SESSIONS_CACHE_TTL_SECONDS cache, so the same DB re-emits the same
warning on every cache miss. The condition is a property of the DB
file, not of the poll.

Fix: a module-level `_SOURCE_COLUMN_WARNED_DB_PATHS: set[str]` keyed by
the resolved db_path. The warning fires the first time a given path is
seen in the process and is suppressed after that; a different path
warns on its own. Message text is unchanged. Process-lifetime only: a
restart warns again, which is intended (the line remains the operator's
cue that the agent still needs upgrading). Plain set mutation under the
GIL is sufficient; a duplicate line from two racing first calls is
harmless.

Tests (tests/test_issue634.py, real pre-`source` sqlite DBs under
tmp_path, asserting on captured log records):
- same db_path called twice -> exactly one WARNING (failed before:
  `assert 2 == 1`)
- two db_paths, then the first again -> exactly two WARNINGs, one per
  path (failed before: `assert 3 == 2`)
The seven existing #634 source-shape tests still pass; neighbours
test_issue3762/3930/5455/1494 pass.

Deliberately not changed: the exception-path warning in
get_cli_sessions() (api/models.py), the read-only-open fallback warning,
and the 5 s cache TTL. The operator-side root cause (the agent
reconciler creating a pre-`source` state.db) is a separate upstream fix;
this only stops the repetition.
2026-09-08 22:38:07 -03:00
nesquena-hermes 7d56234ea4 Merge pull request #7473 from nesquena/stage/7082
Release exp-v0.52.278: stop tearing live progress words (#7082, @ruizanthony)
2026-09-08 14:53:01 -07:00
n b52f5b1f0e changelog: #7082 stop tearing live progress words (@ruizanthony) 2026-09-08 21:48:18 +00:00
n 049a1ef3de stage: merge #7082 (stream word-tearing) 2026-09-08 21:16:39 +00:00
nesquena-hermes 1f2c7abef0 Merge pull request #7469 from nesquena/stage/7356
Release exp-v0.52.277: keep provider hint for slash-id picks (#7356, @Manny7717)
2026-09-08 11:45:02 -07:00
n 4717dc97f2 changelog: #7356 keep provider hint for slash-id picks (@Manny7717) 2026-09-08 18:38:41 +00:00
n ad620c3211 stage: merge #7356 (provider-hint slash-id) 2026-09-08 18:20:45 +00:00
nesquena-hermes 5efc635488 Merge pull request #7468 from nesquena/stage/7277
Release exp-v0.52.276: guard submitEdit against re-entry (#7277, @alanjds)
2026-09-08 10:46:47 -07:00
n 38462d7cbd changelog: #7277 guard submitEdit re-entry (data-loss prevention, @alanjds) 2026-09-08 17:40:31 +00:00
n 649083eb7f stage: merge #7277 (submitEdit re-entry guard) 2026-09-08 17:22:39 +00:00
nesquena-hermes 3fae64a9e1 Merge pull request #7466 from nesquena/stage/5888
Release exp-v0.52.275: read-only child session ordering (#5888, @igorroncevic)
2026-09-08 09:59:51 -07:00
n f765e8178d ci: re-trigger (test_warm_models_catalog_provenance flake — network-timing, unrelated to this sessions.js-only diff) 2026-09-08 16:53:34 +00:00
nandigorroncevic 6cac3244d7 changelog: #5888 read-only child session ordering (@igorroncevic)
Co-authored-by: igorroncevic <igorroncevic@users.noreply.github.com>
2026-09-08 16:44:00 +00:00
n a1f8c51e6b stage: #5888 read-only child session ordering (@igorroncevic) 2026-09-08 16:43:05 +00:00
nesquena-hermes 10104dd82b Merge pull request #7465 from nesquena/stage/7335
Release exp-v0.52.274: inline handler arg escaping (#7335, @zicochaos)
2026-09-08 09:32:01 -07:00
nandzicochaos 2d391310f8 changelog: #7335 jsArg inline-handler escaping (@zicochaos)
Co-authored-by: zicochaos <zicochaos@users.noreply.github.com>
2026-09-08 16:24:06 +00:00
n 990a92a18e stage: #7335 jsArg inline-handler escaping (@zicochaos) 2026-09-08 16:05:36 +00:00
nesquena-hermes 3599d1f896 Release: nested mixed ul/ol list hierarchy, iteratively serialized (#6716, @webtecnica) (#7463)
Release: nested mixed ul/ol list hierarchy, iteratively serialized (#6716, @webtecnica)
2026-09-08 08:22:50 -07:00
n de742f64ef docs(changelog): stamp #6716 nested mixed-list renderer + iterative serializer 2026-09-08 15:14:52 +00:00
n cedc2ffc22 Merge PR #6716 re-push for re-gate 2026-09-08 14:54:50 +00:00
nesquena-hermes be5c071750 Release: skill-not-found reply discloses truncation (#7428, @elight) (#7460)
Release: skill-not-found reply discloses truncation (#7428, @elight)
2026-09-07 23:56:12 -07:00
n 5df1470619 docs(changelog): stamp #7428 skill-not-found truncation disclosure 2026-09-08 06:48:29 +00:00
n 4311143c12 Merge PR #7428 for gate 2026-09-08 06:29:12 +00:00
nesquena-hermes 1ab000069c Release: port out-of-band normalizers to the transport API (#7402, @zicochaos) (#7459)
Release: port out-of-band normalizers to the transport API (#7402, @zicochaos)
2026-09-07 22:49:24 -07:00
n a946b616c8 docs(changelog): stamp #7402 transport-normalizer port 2026-09-08 05:41:51 +00:00
n 2a804ae38d Merge PR #7402 for gate 2026-09-08 05:23:11 +00:00
nesquena-hermes 4b47cfa12d Release: streaming echo-suffix fold O(n^2)->O(n) (#7288, @ruizanthony) (#7458)
Release: streaming echo-suffix fold O(n^2)->O(n) (#7288, @ruizanthony)
2026-09-07 22:05:28 -07:00
n 07f1a1405a docs(changelog): stamp #7288 streaming echo-fold perf fix 2026-09-08 04:51:10 +00:00
n edf6c6a686 Merge PR #7288 for re-gate on current master 2026-09-08 04:37:42 +00:00
webtecnica 2c0b4902d0 fix(renderer): emit nested lists iteratively to avoid stack overflow (#6700) 2026-09-08 01:16:01 -03:00
webtecnica 660d54af63 test(renderer): mirror nests same-marker child lists inside parent li (#6700)
greptile P2: the Python mirror's handle_ul/handle_ol closed the parent
<li> before opening the child <ul>/<ol> for same-marker nested lists
('- parent\n  - child'), so structural assertions passed without
validating renderMd()'s parent-child hierarchy. Child lists now render
inside the parent <li>, byte-matching renderMd() for the two-level case;
adds a mirror regression test asserting the exact nested structure.
2026-09-08 01:16:00 -03:00
webtecnica b810e5466f fix(renderer): preserve ordered flag on list items (#6700)
openItem() received ordered but dropped it from the item constructor, so
it.ordered was always undefined and every item looked unordered at the
task-list check. An ordered item whose text begins with [x] or [ ] (e.g.
'1. [x] shipped') was silently converted to a task icon and lost its
literal prefix. Task-list rendering now applies only to unordered items.
2026-09-08 01:16:00 -03:00
webtecnica 13dd97d60d fix(renderer): preserve nested mixed ul/ol list hierarchy (#6700) 2026-09-08 01:16:00 -03:00
nesquena-hermes 641878bd88 Release: extension archive dotfile allowlist (#6620, @asorourx) (#7457)
Release: extension archive dotfile allowlist (#6620, @asorourx)
2026-09-07 20:27:37 -07:00
n d53587d77a docs(changelog): stamp #6620 extension archive dotfile allowlist 2026-09-08 03:14:02 +00:00
n e69d681e82 Merge PR #6620 for exact-head re-gate 2026-09-08 03:01:00 +00:00
nesquena-hermes 6e6893f3ae Phase 1 Batch 2: passkey-behind-proxy + opt-in pipe trusted-groups (#7456)
Phase 1 Batch 2: passkey-behind-proxy (#6772) + opt-in pipe trusted-groups (#7331)
2026-09-07 19:21:27 -07:00
n 286c5e3336 docs(changelog): #7331 pipe separator is opt-in 2026-09-08 01:53:18 +00:00
n e7841a5988 gate fixes: opt-in pipe separator (#7331) + IPv6-safe Origin (#6772)
Two Codex adversarial-security-gate findings on the batch:

1. #7331 CORE (backward-compat break): making '|' an unconditional trusted-groups
   separator would re-split an existing deployment whose group NAME legitimately
   contains a literal '|' (e.g. 'unprivileged|admins' read as one group), silently
   changing its profile binding. Pipe splitting is now OPT-IN via
   HERMES_WEBUI_TRUSTED_GROUPS_PIPE_SEPARATOR; comma/newline stay the default.
   Tests: literal-pipe preserved by default, pipe splits only with the flag set.

2. #6772 follow-up (my own hardening introduced it): rebuilding the origin from
   parsed parts dropped the brackets around an IPv6 host, so 'http://[::1]:8787'
   became 'http://::1:8787' and never matched the browser's bracketed
   clientDataJSON.origin -> passkey login over IPv6 would fail. Re-bracket IPv6
   literals. Added rp_context regression tests (Origin-first, port preserved,
   IPv6 bracketed, malformed->Host fallback, userinfo stripped).
2026-09-08 01:53:01 +00:00
n 2e62c4f896 docs(changelog): stamp Phase-1 batch 2 security fixes (#6772, #7331) 2026-09-08 01:31:45 +00:00
n 289b539bc4 harden(passkeys): accept only a well-formed http(s) Origin for RPID derivation
Follow-up on #6772. Preferring Origin over Host for the WebAuthn RPID is correct
(the RPID must match the page origin, not the backend's), and it is not a trust
decision: the authenticator only releases a credential whose RPID is a registrable
suffix of the real page origin, clientDataJSON.origin must equal the stored origin,
rpIdHash must match the stored RPID, and the assertion signature is verified against
the stored credential public key.

Still, only accept a syntactically valid http(s) Origin carrying a hostname, and
rebuild the stored origin from the parsed scheme/host/port instead of echoing the raw
header — so a malformed, non-http (javascript:/file:), or userinfo-bearing Origin
falls through to the Host-derived path rather than being stored verbatim.
2026-09-08 01:31:26 +00:00
n 0f76602790 Merge PR #7331 2026-09-08 01:30:36 +00:00
n 1e00ef131b Merge PR #6772 2026-09-08 01:30:35 +00:00
nesquena-hermes 49c6f98f82 Phase 1 Batch 1: seven low-risk contributor fixes (#7455)
Phase 1 Batch 1: seven low-risk contributor fixes (+2 gate follow-ups)
2026-09-07 18:28:12 -07:00
n 7ee8e43392 docs(changelog): stamp Phase-1 batch 1 (#7427 #7207 #7447 #7385 #6768 #7430 #6330) 2026-09-08 00:59:17 +00:00
n a8d10887df fix(picker): don't let a separator-only search match every model
Codex gate finding on #7385: the new fold-matching (#7228) normalizes the search
term by stripping [\s._-], so a separator-only query ('.', '-', '_') folds to '' and
String.includes('') is always true — every model matched. Verified: searching '.'
returned all models, including ids with no dot.

Guard the folded clauses with a non-empty foldTerm, keeping the literal
name/id includes() checks so '-' still matches ids that really contain one.
Real searches ('ox alpha' / 'ox-alpha' / 'sonnet') are unchanged.
2026-09-08 00:58:05 +00:00
n 150c766875 fix(transcript): mount the render window when jumping to session start mid-stream
Codex gate finding on #7427: moving _scheduleMessageVirtualizedRender() below the
_freshProgrammaticScrollActive() guard (the idle re-render-loop fix) removed the ONLY
thing that mounted the new render window on the jumpToSessionStart() streaming path,
which deliberately skips renderMessages(). Reproduced in Chromium: 160 rows produced a
14,827px spacer and zero visible rows (blank transcript) where master mounted correctly.

Schedule the virtualized render explicitly in the streaming branch, after invalidating
_messageVirtualWindowKey, preserving #7427's listener guard and its idle-loop fix.
2026-09-08 00:26:54 +00:00
n 94b70ce8b8 Merge PR #7385 2026-09-08 00:16:17 +00:00
n d52596a269 Merge PR #7427 2026-09-08 00:16:17 +00:00
n f8ade25db9 Merge PR #7207 2026-09-08 00:16:17 +00:00