Skip to content

main's CI is green: the canary expects memory.get's served fields, the analyzer shapes carry the new schema dump, and the coalescer windows test does not race its timers - #350

Merged
zlareb1 merged 4 commits into
mainfrom
fix/main-red-served-fields
Nov 7, 2026

Conversation

@zlareb1

@zlareb1 zlareb1 commented Nov 7, 2026 •

Copy link
Copy Markdown
Member

Changelog category (leave one):

  • CI Fix or Improvement (changelog entry is not required)

Changelog entry (one or two sentences a user of Loom can read without the diff; the release pull request collects these into the release notes):

...

Why

main's CI has three failures in four jobs:

  • pytest integration part 2 of 4 and pytest integration isolation gates: tests/integration/test_sensitivity_high_canary.py::test_payment_and_identity_numbers_are_labelled_on_write (5 cases) compares memory.get's answer field by field. The inspector's Last recalled counts every agent read that served a memory #311 added served_count and last_served_at to MemoryGetOutput; both are None unless the call sets include_recall_breakdown. The diff the job prints: Left contains 2 more items: {'last_served_at': None, 'served_count': None}.
  • tests/analyzer/test_corpus.py::test_shapes_file_matches_builders: statement shapes changed: 1 new, 1 gone. The one shape is schemas/schema.sql itself, whose hash moved when migration 084 was added; tests/analyzer/shapes.txt was not regenerated.
  • pytest unit part 6: tests/unit/test_sdk_set_coalescer.py::test_windows_of_many_identities_do_not_pile_up fails with assert co._windows / assert {}. The test sends 200 sets, one per session, so each opens its own window and goes out as a direct memory.set, and it checked that windows existed after gather. gather returns only after every direct set has come back, and each window's timer closes it 10 ms after it opened; when the 200 sets take longer than that, as on a loaded runner, every window is already closed. A 20 ms fake memory.set reproduces it every time.

The canary now lists the two fields with the reason they are None, and shapes.txt is regenerated with python -m tests.analyzer.corpus --write: one line, the schema dump's hash. The coalescer test counts the windows one loop turn after the sets start, when every set has opened its window and no timer can have run, then gathers them; its final check, that every window ends at its time, is unchanged.

The three are in one PR because each red job would block the others' fix from a green run.

Scope and risk

Three test files; no server or SDK code.

Compatibility, rollout and rollback

  • Wire: none.
  • Operator steps: none.
  • Rollback: revert.

Tests

  • tests/integration/test_sensitivity_high_canary.py and tests/integration/test_served_reads.py against a server from this branch (migrated through 084): 16 passed.
  • tests/unit/test_sdk_set_coalescer.py: 46 passed; the test with a 20 ms fake memory.set fails on main and passes here.
  • tests/analyzer/test_corpus.py -k "shapes_file or every_axis": 3 passed; it fails on main as quoted above.

AI assistance in the code (leave one; writing this description with AI is fine):

  • AI-generated (an agent wrote most of the diff): Claude Code; the CI logs and the regenerated shape were checked by hand.

  • I can explain every line of this diff and how it interacts with the rest of Loom.

Checklist

  • make format-check, make lint, make typecheck and make test-unit pass; the integration suite passes if server behaviour changed.
  • Generated files are regenerated in this PR, not by hand.
  • A new migration is additive and numbered after the latest on main; no merged migration is edited.
  • A behaviour change to any file a plugin ships bumps both plugin manifests' version.
  • The frontend builds and its tests pass, if frontend/ changed.
  • Docs under docs/ describe the system as it now is, and this description names any operator steps and wire changes.
  • Repository text has no dates, people, host names, internal namespaces, ticket or decision numbers.
  • Commits are signed off (git commit -s), as CONTRIBUTING.md asks.

🤖 Generated with Claude Code

@zlareb1
zlareb1 force-pushed the fix/main-red-served-fields branch from db6765d to 1b7a1ad Compare November 7, 2026 10:51
zlareb1 and others added 3 commits November 7, 2026 11:05
…alyzer shapes carry the new schema dump

main's integration part 2 and isolation gates failed on test_payment_and_identity_numbers_are_labelled_on_write: memory.get now answers served_count and last_served_at (None without include_recall_breakdown), and the test compares every field. tests/analyzer/test_corpus.py failed too: schemas/schema.sql gained migration 084, so its shape hash in tests/analyzer/shapes.txt moved. The test lists the two fields; shapes.txt is regenerated with python -m tests.analyzer.corpus --write (one hash).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
…s are out, so a slow runner cannot close them first

The test checked that windows existed after gathering 200 direct sets; when those took longer than the 10 ms window, every timer had already closed its window and the precondition failed. It now counts the windows one loop turn after the sets start, before any timer can run.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
@zlareb1
zlareb1 force-pushed the fix/main-red-served-fields branch from 1b7a1ad to 681ddc2 Compare November 7, 2026 11:06
@zlareb1 zlareb1 changed the title The sensitivity canary expects memory.get's served fields, and the analyzer shapes carry the new schema dump main's CI is green: the canary expects memory.get's served fields, the analyzer shapes carry the new schema dump, and the coalescer windows test does not race its timers Nov 7, 2026
…le's other tests do

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
@zlareb1
zlareb1 merged commit 256803e into main Nov 7, 2026
34 checks 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