Skip to content

Sync phase 1: upstream v0.9.29 bugfixes onto chronode main - #5

Merged
ChronodeAi merged 9 commits into
mainfrom
sync/v0.9.29-phase1
Aug 24, 2026
Merged

Sync phase 1: upstream v0.9.29 bugfixes onto chronode main#5
ChronodeAi merged 9 commits into
mainfrom
sync/v0.9.29-phase1

Conversation

@ChronodeAi

Copy link
Copy Markdown
Owner

Summary

Phase 1 of the staged v0.9.29 upstream sync (analysis: 17 upstream commits classified; this train takes the bugfixes the deployed 0.9.28-chronode.12 suffers from today).

Picked / ported:

Deliberately skipped: a7114c7 (rewrites basename-resolver tests we replaced wholesale with canonical-resolver fixtures).

Count surfaces reconciled to measured reality after the new tool/route: MCP tools 58/59→60 across test constant, README (badge + prose), plugin manifests, AGENTS.md, autogen skill references (regenerated via npm run skills:gen, no diff), code comments; REST endpoints 135→136 in README/AGENTS/boot banner/generated inventory. R13 test manifest content hash re-stamped for the negotiation tests.

Test plan

  • npx vitest run: 1794 tests — all pass except cli-connect.test.ts > repairs hooks without --force…, which fails identically on unmodified main @ 473a093 (pre-existing, tracked separately)
  • tsc --noEmit -p tsconfig.json: zero new errors vs baseline (pre-existing transport.ts/tools-registry.ts schema-type errors unchanged)
  • node scripts/r13/run.mjs --preflight-only: passes with mandatory + project-capability credentials configured

txtsamu and others added 9 commits August 24, 2026 11:21
…0#1134)

The rohitg00#625 fix removed the memory/ subdirectory and pointed the bridge at
~/.claude/projects/<slug>/MEMORY.md. Claude Code 2.x actually stores
project memory at ~/.claude/projects/<slug>/memory/MEMORY.md (the index)
plus per-topic .md files in the same memory/ dir — verified against the
Claude Code 2.1.141 bundle (constants memory/MEMORY.md) and an existing
project memory dir on disk.

With the current path the bridge writes a MEMORY.md that Claude Code
never reads, so CLAUDE_MEMORY_BRIDGE is silently broken on every
platform. Restore the memory/ segment while keeping the leading-dash
slug fix from rohitg00#625, and update the path tests accordingly.

Co-authored-by: txtsamu <txtsamu@users.noreply.github.com>
…itg00#1132)

* fix(memory): guard mem::forget delete/count on record existence

Calling mem::forget with a lesson id (lsn_*) deleted a nonexistent key
from the memories keyspace, counted it, and reported success. Guard the
delete, index cleanup, and counter on the kv.get result, matching the
mem::governance-delete pattern, so nonexistent ids return
{ success: true, deleted: 0 } with no audit row. Closes rohitg00#1120.

* feat(lessons): add mem::lesson-delete soft-delete function

Register mem::lesson-delete to set deleted: true on a lesson, mirroring
the lesson-strengthen existence guard and audit pattern. Read paths
already filter !l.deleted, and re-saving deleted content creates a fresh
lesson. Adds lesson_delete to the audit operation union.

* feat(mcp): expose memory_lesson_delete tool and REST endpoint

Wire mem::lesson-delete through the MCP tool registry and dispatch
case (memory_lesson_delete) and a POST /agentmemory/lessons/delete REST
route with 400 for a missing lessonId and 404 for a nonexistent lesson.

* chore(consistency): bump tool/endpoint counts to 54/129

Adds memory_lesson_delete to the registry, so update every count surface:
tool-count test, README badge and prose, AGENTS.md stats,
INSTALL_FOR_AGENTS.md, plugin manifests and docs, and the two code
comments this change makes stale. REST endpoint count goes 128 to 129
for the new /agentmemory/lessons/delete route.

* refactor(lessons): simplify 404 mapping and restore decay-delta test

Cast the lesson-delete trigger result once instead of twice inline, and
restore the lastDecayedAt incremental-delta decay test that was dropped
when the lesson-delete describe block was added.

* fix(review): align 404 error shape and regenerate skill references

Review fixes: the lesson-delete REST route now returns the repo-standard
{ error: 'lesson not found' } body on 404 instead of the function-shaped
{ success: false } payload, matching api::memory-by-id. Regenerated the
autogen MCP and REST skill references so memory_lesson_delete and the
lessons/delete route appear in the tables with accurate counts.

* fix(lessons): normalize lessonId at entry points and harden no-op test

Address CodeRabbit review: trim lessonId once at both the MCP dispatch
and REST route before triggering mem::lesson-delete (whitespace-padded
ids previously 404'd or looked up raw), and extend the nonexistent-
memoryId regression test to assert the no-op path performs no kv.delete
and no search-index cleanup.

---------

Co-authored-by: Rohit Ghumare <48523873+rohitg00@users.noreply.github.com>
Restore the memory_lesson_delete registry definition lost in conflict
resolution, bump every count surface (test constant, README badge and
prose, plugin manifests, AGENTS.md, autogen skill references, code
comments) from the drifted 58/59 to the measured 60, and regenerate
skill references so the generator output matches hand-resolved content.
Port of upstream rohitg00#908 fix (a2a2af9, subset): initialize echoes the
client's requested revision when it is one we support and answers with
the newest supported revision otherwise, so hosts requiring a newer MCP
revision stop disconnecting with -32000. Strict tool discovery and the
local fallback policy are unchanged; four handshake tests pin the wire
behavior.
The cherry-picked REST registration bypassed registerApiTrigger, so the
route shipped without middleware::api-auth and failed the
every-route-protected invariant. Also refresh the generated interface
inventory for the new route.
mcp-standalone.test.ts gained the initialize negotiation block; the
tracked-tests list is unchanged, so only content_sha256 moves.
README prose, the banner-adjacent toolkit line, AGENTS.md stats, the
boot banner in src/index.ts, and the generated interface inventory now
agree with the registered route table.
The interface-inventory gate hardcoded pre-sync counts; align it with
the regenerated inventory so CI matches the reconciled surfaces.
The committed hook bundles are build outputs; CI rebuilds them and the
stale shim made the R13 runner see a dirty worktree. Rebuilt via
npm run build after the protocolVersion change.
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.

3 participants