Skip to content

Add guarded engineering intake and review controls - #65

Merged
FlyOverCoderKY merged 7 commits into
mainfrom
codex/pg02-engineering-current-20261111
Nov 12, 2026
Merged

FlyOverCoderKY merged 7 commits into
mainfrom
codex/pg02-engineering-current-20261111

Conversation

@FlyOverCoderKY

Copy link
Copy Markdown
Contributor

Changes

  • Add the essential signed-in engineering intake and review controls using the verified five-package Support Desk 0.2.6 release.
  • Bind all seven mutations to current human authority at the SDK commit boundary. Retain immutable repository key, ID and descriptor binding for exact accepted selection recovery after catalog removal.
  • Support held and rejected acknowledgements, protected evidence recovery, independent engineering read/control budgets, and narrow-panel layout.
  • Extend the existing exclusive cleanup rotation from 16 to 18 lanes for the two bounded engineering limiter namespaces.

The current Knowledge authoring profile, three registered clients and query redaction from PR #64 are included through the rebased main parent. Engineering processing, GitHub export and customer AI remain off.

Validation

The post-rebase frozen install, check and build passed. All 1,292 Node tests and 41 relevant real Native D1 tests passed with zero skips. The measured HTTP profiles use at most 46 physical D1 calls and four parameters under the 50/100 guards.

A prior whole local Native run recorded 147/148, with the existing high-history Knowledge test reaching its timeout. The current Linux CI run must execute the complete suite. The source has retained those earlier results and the later focused results accurately.

The current Sessions 0.2.0 dependency has a confirmed default-clock concurrency defect. The 0.2.1 patch is under review in pegma-dev/sessions#15. Verified patch adoption and deployed workflow qualification follow before pilot activation.

PR review uses the OpenRouter pull-request review action and the configured CI checks.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 11, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
🔒 Security Review ✅ Completed 2026-11-11T20:25:05.468517Z ec0058b PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Nov 11, 2026 •

Copy link
Copy Markdown

OpenRouter review posted (clean). #65 (review)

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OpenRouter pull-request review

Verdict: issues
Scope: full-pr (full-pr)
Mode: initial
Commit: ec0058b34fa5f8bceb2f9dd1d1e07e27f6186de9
Judge: openai/gpt-5.6-luna (repaired(canonical+1): source coverage preserved before publication cap)
Cost: $0.8368 (lanes $0.8307 + judge $0.0060)

Lanes

  • openai/gpt-6.1-sol: ok (8 finding(s), 142.5s, 889059+5562 tokens (751358 cached), 6 tool round(s), via Azure, $0.52)
  • z-ai/glm-5.3-flash: ok (5 finding(s), 465.6s, 7629709+74959 tokens (7280704 cached), 41 tool round(s), via Together, $0.31)

Warning

z-ai/glm-5.3-flash: coverage claims 2 finding(s) in 'docs/SUPPORT_ENGINEERING.md' but 1 were reported

Warning

z-ai/glm-5.3-flash: coverage claims 1 finding(s) in 'worker/src/support-engineering-http.d1.test.ts' but 0 were reported

Findings

🔴 Issue 1 — Policy preparation can diverge from the displayed selection

public/staff-support-engineering.js:400 · bug · identified by openai/gpt-6.1-sol

If an administrator changes repository checkboxes or the enabled checkbox while preparation is awaiting its response, Save subsequently submits the earlier selection even though the editor displays the newer selection.

preparePolicy() captures keys and active before awaiting HTTP, but controls() disables only buttons, not the policy inputs. Their change listeners clear preparedPolicy; the outstanding response then repopulates it with the obsolete intent. There is no indication of which selection was actually prepared.

I checked the preparation response validation and the change listeners in policyRead(). They bind the response to the original request, but do not compare it with the current editor or invalidate an outstanding preparation. Disable editing during preparation or fence the response with an editor generation.

🔴 Issue 2 — Source mutations leave an obsolete proposal actionable

public/staff-support-engineering.js:245 · bug · identified by openai/gpt-6.1-sol

After reading an approvable proposal, a staff member can record replacement evidence or invalidate the source and still see the old proposal with Approve enabled. Clicking it sends the obsolete command, which can become a permanently retained, never-accepted review and block further ticket actions.

refreshSource() clears source and work, but not proposal or proposalText. Successful evidence, invalidation, withdrawal and repository-selection flows do not otherwise retire the proposal. controls() admits approval from the retained proposal.approvable flag without comparing its source/work generations with the refreshed state.

I checked the SDK-facing generation fences and the review tests: they prevent a stale approval from committing, but the panel deliberately retains failed commands rather than resolving them. The tests cover stale review recovery, not invalidating an already rendered proposal through another panel mutation. Clear the proposal whenever its source or work is replaced.

🔴 Issue 3 — Read throttling blocks independent mutation recovery

public/staff-support-engineering.js:207 · bug · identified by openai/gpt-6.1-sol

If a source/work/policy read exhausts the engineering read quota while a mutation is retained, explicit recovery of that mutation is delayed until the read quota's deadline—even when the independent mutation quota remains available. A read Retry-After can therefore block withdrawal or exact write recovery for nearly an hour.

Every 429 updates the single retryAt in failure(), and every mutation in send() consults that same deadline. Ticket and policy operations also share it. This couples the separate server policies at the browser boundary.

I checked support-desk.ts, handler limiter selection, and the quota tests in support-engineering-composition.test.ts. Those establish independent read and mutation budgets. The UI retry test exercises only mutation throttling, so it does not disprove this cross-policy blocking. Track backoff by the limiter purpose rather than applying read deadlines to writes.

🔴 Issue 4 — Direct proposal review ignores configured review proofs

worker/src/support-engineering.ts:257 · bug · identified by openai/gpt-6.1-sol

A trusted caller constructing a runtime with only reviewProofs cannot approve through runtime.reviewProposal(): that entry point uses the unavailable base proof ports instead of the explicitly supplied read-only proofs.

reviewBase incorporates options.reviewProofs, and reviewCommand() constructs its coordinator from it. In contrast, reviewProposal() calls coordinator, which was constructed from base. The two public human-review entry points thus behave differently under the supported proof-only composition.

I checked the current direct callers in support-engineering-fixtures.ts and the runtime tests; they supply full ports, masking the discrepancy. The proof-only approval test goes through HTTP and therefore exercises reviewCommand() only. Use the review-specific coordinator for both entry points.

🟠 Issue 5 — Native HTTP qualification omits review and late-denial paths

worker/src/support-engineering-http.d1.test.ts:226 · risk · identified by openai/gpt-6.1-sol

Enabling human proposal review can introduce an unqualified D1 request profile: approval performs additional proof and current-authority reads, but no Native HTTP test establishes that those requests stay within the 50-call guard. Late authority denial adds another closing authorization path that is also unmeasured.

The metered engineering HTTP suite covers intake, selection, policy, successive role revocation and cold-root enrollment/detail/policy. It never issues an engineering proposal GET or review POST, and it does not revoke authority during a measured request. The Native SDK review test bypasses browser authentication and the limiter, so it cannot establish the HTTP budget.

I searched worker/src for proposal/review request calls and inspected support-engineering-http.d1.test.ts, support-engineering.d1.test.ts, and the Memory review/human-mutation tests. The actual call count for these omitted paths remains a material proof gap, not a demonstrated budget overflow. Add Native HTTP profiles for approval, rejection, exact review replay and late current-authority denial.

🟠 Issue 6 — New concurrent human-mutation surface composed on the disclosed defective Sessions 0.2.0

package.json:45 · risk · identified by z-ai/glm-5.3-flash

The PR body itself states: "The current Sessions 0.2.0 dependency has a confirmed default-clock concurrency defect. The 0.2.1 patch is under review… Verified patch adoption and deployed workflow qualification follow before pilot activation." This PR ships a second concurrent staff surface on top of that dependency: each engineering HTTP request runs multiple session validations (supportHumanBrowser.current() performs sessions.get twice per current() and current() is invoked at admission, before commit, and in the response/catch fence), and the panel's retained-owner recovery can drive overlapping engineering mutations and reads from the same or multiple tabs alongside the ordinary surface.

Concrete cost: once the engineering composition is enabled, a larger share of session reads/mutations flows through the dependency the PR declares defective, under concurrency patterns (committed-ACK loss plus explicit retry from a second tab) that the ordinary surface exercised less. The mitigation is sequencing (engineering stays OFF in the default Worker and activation is gated), but the expanded surface is merged before the fixed dependency is adopted.

Evidence: package.json:45 pins @​pegma/sessions 0.2.0; the lockfile hunk in this PR touches only the support-desk packages, so the defective version is intentionally carried forward. Counterevidence checked: no caller in this PR changes session-store semantics, and the defect is pre-existing and disclosed — hence risk, not bug.

🔵 Issue 7 — Current package documentation still identifies version 0.2.5

docs/SUPPORT_COMPOSITION.md:20 · nit · identified by openai/gpt-6.1-sol

An operator following the existing composition guides will identify or qualify the wrong Support Desk release after this upgrade. The new engineering guide says 0.2.6, while the main composition guide still lists all five installed packages as 0.2.5 and calls that graph current.

Affected current-selection statements include:

  • docs/SUPPORT_COMPOSITION.md: the package inventory at lines 20–24 and current selection at lines 278–287.
  • docs/SUPPORT_ASSISTANT_STAGE.md: the current package selection at line 54.
  • docs/KNOWLEDGE_COMPOSITION.md: the host selection at line 24.
  • docs/SUPPORT_LEARNING.md: the host selection at line 18.

I compared these statements with package.json and pnpm-lock.yaml. Historical 0.2.5 checkpoint results should remain historical; current-version inventories and qualification wording should distinguish them from the new graph.

🔵 Issue 8 — Knowledge runbook retains the old cleanup rotation

docs/KNOWLEDGE_COMPOSITION.md:403 · nit · identified by openai/gpt-6.1-sol

An operator estimating Knowledge physical-recovery opportunities from its runbook will use a 16-lane rotation even though this change reduces those opportunities to one per 18 eligible ticks.

docs/KNOWLEDGE_COMPOSITION.md still describes 16 exclusive lanes at line 403 and links to a “16-lane cleanup schedule” at line 475. The implementation and updated Worker README now use 18 lanes.

I checked the shared CLEANUP_LANE_COUNT, the scheduler dispatch and the updated rotation tests. This is documentation drift rather than a scheduler defect; update the Knowledge maintenance description alongside the Worker runbook.

🔵 Issue 9 — Engineering recovery warning names a learning action

public/staff-support-ticket.js:793 · nit · identified by openai/gpt-6.1-sol

When the ticket address changes with only an engineering command retained, clicking Reload warns that “an earlier learning action may have completed.” This misidentifies the unresolved operation at the point where the user must preserve its original ticket coordinates.

The condition was broadened to learningPending() || engineeringPending(), but the message was not broadened with it.

I checked the retained engineering owner controls and the reload handler. They correctly prevent navigation-based loss; use a generic retained-action warning or identify the actual pending domain.

🔵 Issue 10 — Commit-boundary principal assertion is vacuous while docs claim it re-checks identity

worker/src/support-engineering.ts:138 · nit · identified by z-ai/glm-5.3-flash

An auditor relying on docs/SUPPORT_ENGINEERING.md lines 117-118 ("that guard supplies the final synchronous deadline and principal assertion at the Application transaction boundary") gets no principal check there: assertCurrent() compares original.principalId !== bound.principalId, but bound is structuredClone(original) taken before the run, so the two are always equal and the SupportDeskAuthorizationError branch can never fire. The closure handed to the SDK as the final synchronous proof assertion can only ever fail on the deadline.

Identity is still enforced earlier in the flow (command()'s verifyBeforeCommit does check current.principalId !== principalId, and refresh() re-resolves roles), so there is no missing enforcement today — the defect is the dead check plus the doc overclaim. Concrete cost: a future refactor that stops cloning bound (or reorders the clone) would leave this check silently asserting an identity it never verifies, and the documentation leads reviewers to believe a commit-boundary identity re-assertion exists.

Evidence: worker/src/support-engineering.ts:130-141 (bound = structuredClone(original) at 130, assertCurrent at 136-141); counterevidence checked: the earlier verifyBeforeCommit principal check at the command() control builder, which is why no runtime test catches the vacuous branch.

🔵 Issue 11 — Docs still claim the current source selects Support Desk 0.2.5 after the 0.2.6 bump

docs/SUPPORT_COMPOSITION.md:20 · nit · identified by z-ai/glm-5.3-flash

package.json and the lockfile now select @​pegma/support-desk-* 0.2.6 (and worker/README.md was reworded to say "exact 0.2.6 versions" / "earlier public 0.2.5 graph"), but several documents still describe 0.2.5 as the current selection. A qualifier reading them would validate the wrong release.

Stale current-state claims:

  • docs/SUPPORT_COMPOSITION.md:20-24 — "Exact published versions" list of all five Support Desk packages at 0.2.5.
  • docs/SUPPORT_COMPOSITION.md:34,48 — "Verified Support Desk 0.2.5 release" and "The current public 0.2.5 graph has passed…".
  • docs/SUPPORT_COMPOSITION.md:278-279,287,357 — "The current source selects all five published Support Desk 0.2.5 packages…", "use the published, strictly verified Support Desk 0.2.5 APIs", "0.2.5 selection".
  • docs/SUPPORT_LEARNING.md:18 — "The host selects all five published Support Desk packages at 0.2.5".
  • docs/SUPPORT_ASSISTANT_STAGE.md:54 — "The current package selection is Support Desk 0.2.5".
  • docs/KNOWLEDGE_COMPOSITION.md:24 — "Desk packages at 0.2.5, including the optional AI coordinator".
  • worker/src/support-learning-ports.ts:43 — comment "Support 0.2.5 uses the same exact KB 0.1.5 public contracts as this host." (least severe; historical phrasing).

Historical checkpoint references that were deliberately reworded (e.g. worker/README.md:263) are fine. Evidence: the package.json/lockfile hunks in this PR; the inconsistency found by grepping 0\.2\.5 across the repo.

🔵 Issue 12 — SUPPORT_COMPOSITION.md maintenance and policy sections contradict this PR's 18-lane rotation and policy-6

docs/SUPPORT_COMPOSITION.md:263 · nit · identified by z-ai/glm-5.3-flash

This PR extends the exclusive cleanup rotation from 16 to 18 lanes for the two engineering limiter policies and bumps the stored-role policy to pegma.dev-policy-6, and it updates worker/README.md accordingly — but the parallel sections of docs/SUPPORT_COMPOSITION.md (which this PR also edits) still describe the old state:

  • Line 263: "All four are swept by the same rotating cleanup schedule, one policy per invocation" — the support-side durable limiters are now six (pegma.support.ticket.create, pegma.support.ticket.reply, pegma.admin.role.mutate, pegma.admin.principal.lookup, plus the two new pegma.support.engineering.read / pegma.support.engineering.mutate), and the list at lines 255-258 omits the engineering policies entirely.
  • Line 377: "Each task runs once per sixteen eligible ticks (minute 59 is omitted)" — with 18 lanes each lane now runs every ~18 eligible ticks (worker/README.md says "every 18 ticks (a nominal 18-19 minutes)").
  • Line 304: "Policy pegma.dev-policy-5 adds four explicit learning permissions to Support" stated in present tense directly under a document whose header (line 81) now declares pegma.dev-policy-6, with no note of the succession.

Concrete cost: docs/SUPPORT_COMPOSITION.md is the deployment-qualification record referenced by worker/README.md; an operator deriving the cleanup cadence or the policy version from it now gets answers that contradict the code and the README in the same tree. Evidence: worker/src/maintenance-schedule.ts (18 lanes, CLEANUP_LANE_COUNT), worker/src/support-desk.ts (six maintenance limiters), worker/src/support-access.ts (version: 'pegma.dev-policy-6').

🔵 Issue 13 — New doc requires Native D1 proposal/review measurement profiles the PR's own D1 suite lacks

docs/SUPPORT_ENGINEERING.md:233 · nit · identified by z-ai/glm-5.3-flash

docs/SUPPORT_ENGINEERING.md ("Qualification and configuration") states: "Actual registered-route Native D1 measurements must cover intake, policy, proposal, review, recovery and late current-authority denial." The Native D1 suite added in this PR (worker/src/support-engineering-http.d1.test.ts) meters intake (enroll/source0/evidence/source read), policy (prepare, put, lost-ACK replay after catalog drift, stale-catalog refusal, disable), repository selection, invalidate/withdraw, role-revocation denials, router guards, and the registered root composition — but no /proposal or /review request is ever profiled over real D1 (verified by grepping every invoke('…') / budget.run(…) label in that file: there is no proposal or review entry, unlike the node suites which cover proposal/review against the Memory SDK).

Concrete cost: proposal and review are the two most payload-heavy reads/writes (the 64 KiB projection, the retained full review command), and their physical D1 cost against the 50-call/100-parameter guard is unmeasured; activation qualification could proceed believing the documented measurement coverage exists when it does not. The gap is internal to this PR — the requirement sentence and the incomplete measurement suite arrive together.

Evidence: docs/SUPPORT_ENGINEERING.md:233; worker/src/support-engineering-http.d1.test.ts label inventory (lines 141-457). Mitigating context checked: review is 503-disabled by default and requires explicit reviewProofs, so nothing is blocked today — hence nit.

Workflow run

Comment thread public/staff-support-engineering.js Resolved
Comment thread public/staff-support-engineering.js Resolved
Comment thread public/staff-support-engineering.js Resolved
Comment thread worker/src/support-engineering.ts Resolved
Comment thread public/staff-support-ticket.js Resolved
Comment thread worker/src/support-engineering.ts Resolved
Comment thread docs/SUPPORT_ENGINEERING.md Resolved

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OpenRouter pull-request review

Verdict: issues
Scope: latest-commit (commit-range)
Mode: verify
Commit: 23fcfb7c194788af37298b033b1baced7bdbadd6
Judge: openai/gpt-5.6-luna
Cost: $0.2439 (lanes $0.2427 + judge $0.0012)

Lanes

  • openai/gpt-6.1-sol: ok (0 finding(s), 46.0s, 200201+1370 tokens (149378 cached), 4 tool round(s), via Azure, $0.17)
  • z-ai/glm-5.3-flash: ok (1 finding(s), 298.6s, 1137333+41687 tokens (999936 cached), 15 tool round(s), via KT, $0.0715)

Round 2 resolution

  • ✅ r1-1 fixed correctly — Policy preparation can diverge from the displayed selection: preparePolicy() now captures policyEditorRevision and discards the response if the editor changes while preparation is pending. Both repository and enabled-checkbox listeners increment that revision and clear the prepared intent. Regression tests cover both changes and subsequent preparation of the displayed selection.
  • ✅ r1-2 fixed correctly — Source mutations leave an obsolete proposal actionable: refreshSource() now clears both proposal and its rendered text before reading replacement state. Evidence, invalidation, withdrawal and repository-selection acknowledgements all pass through this function; failed operations also clear private state. Added real SDK/HTTP tests verify that invalidation and withdrawal disable review without retaining a stale command.
  • ✅ r1-3 fixed correctly — Read throttling blocks independent mutation recovery: Read and mutation deadlines are now separate, and call() applies each deadline according to the request method, matching the handler's limiter selection. Unknown mutations can be replayed during read throttling; acknowledged commands wait only for their required read refresh. A regression test covers exact mutation recovery while a real read Retry-After remains active.
  • ✅ r1-4 fixed correctly — Direct proposal review ignores configured review proofs: Direct reviewProposal() now constructs its coordinator from reviewBase, just like reviewCommand(), so explicitly supplied reviewProofs are honored. The added test covers proof-only direct approval and receipt-first recovery after repository facts become unavailable.
  • ✅ r1-5 fixed correctly — Native HTTP qualification omits review and late-denial paths: The Native D1 HTTP suite now meters proposal reads, approval, rejection, exact replay, actor mismatch, session and role revocation during approval proof, and closing role denial after commit with receipt recovery. These requests use the existing physical-call and parameter guards. The suite is included by vitest.d1.config.ts and the CI pnpm test command; execution was not performed in this rea…
  • ✅ r1-6 fixed correctly — New concurrent human-mutation surface composed on the disclosed defective Sessions 0.2.0: package.json and the lockfile now select exact @​pegma/sessions@​0.2.1, replacing the disclosed defective 0.2.0 dependency. Current composition documentation identifies the producer concurrency fix and retains host/deployment acceptance gates. The original defective-dependency composition is removed; deployed qualification is not claimed by this review.
  • 7 nit finding(s) from earlier rounds retired (severity floor for follow-up rounds is risk).
  • Open findings after this round: 1 (0 bug-severity).

Findings

🟠 Issue 1 — Version bump leaves stale composition strings in health payload, README and a port comment

worker/src/index.ts:248 · risk · identified by z-ai/glm-5.3-flash

This commit bumps the composed graph to Support Desk 0.2.7, Knowledge Base 0.1.6 and Sessions 0.2.1 (package.json, pnpm-lock.yaml) and updates docs/, but several dependent version strings still name the previous versions, so the deployed host will report a composition it no longer has.

Concrete instances:

  • worker/src/index.ts:248 — the health endpoint's supportDesk.packages literal is '@​pegma/support-desk-application@​0.2.6'; the host now composes 0.2.7.
  • worker/src/index.ts:281 — the health endpoint's identity.sessions literal is '@​pegma/sessions@​0.2.0'; the host now composes 0.2.1.
  • worker/README.md:250 — "composes exact 0.2.6 versions of @​pegma/support-desk-contracts …" and worker/README.md:261 — "@​pegma/support-desk-ai@​0.2.6 package is installed".
  • worker/README.md:100 — "@​pegma/sessions@​0.2.0 stores SHA-256-hashed opaque session identifiers".
  • worker/src/support-learning-ports.ts:43 — this commit edited the comment to "Support 0.2.6 uses the same exact KB 0.1.5 public contracts as this host", yet the host now selects Support Desk 0.2.7 and KB 0.1.6 (per package.json and the lockfile's support-desk-ai@​0.2.7 → knowledge-base-*@​0.1.6 edges), so the edit is wrong on both versions.

Why it matters: this repo treats exact published versions as qualification evidence, and the health detail is the operator-facing readback of the composed graph. After deploy it will deterministically state the superseded versions, contradicting package.json and the 0.2.7/0.1.6/0.2.1 claims in docs/SUPPORT_COMPOSITION.md, docs/SUPPORT_ENGINEERING.md and docs/KNOWLEDGE_COMPOSITION.md.

What I checked: I grepped the whole tree for 0.2.6/0.1.5/sessions@​0.2 — the remaining hits are either historical checkpoints (e.g. docs/SUPPORT_LEARNING.md lines 29/320/343, the 0.2.5 adoption-checkpoint references) or recipe/eval fixtures that explicitly disclaim the host graph (evals/assembly-eval.test.ts, src/data/recipe-backlog.ts). No test asserts the health strings, so CI will not catch the drift. I did not include README.md:26 (@​pegma/sessions@​0.1.0), which was already inconsistent before this PR and was not touched by it.

Workflow run

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OpenRouter pull-request review

Verdict: issues
Scope: latest-commit (commit-range)
Mode: verify
Commit: c784b16e09ec6649354f3602c9d5ac529cd2cc03
Judge: openai/gpt-5.6-luna
Cost: $0.1061 (lanes $0.1044 + judge $0.0016)

Lanes

  • openai/gpt-6.1-sol: ok (0 finding(s), 22.6s, 47181+765 tokens (31647 cached), 3 tool round(s), via Azure, $0.0546)
  • z-ai/glm-5.3-flash: ok (2 finding(s), 482.7s, 579618+51191 tokens (438889 cached), 30 tool round(s), via Crusoe, $0.0498)

Round 3 resolution

  • ✅ r2-1 fixed correctly — Version bump leaves stale composition strings in health payload, README and a port comment: The health payload now reports Support Desk application 0.2.7 and Sessions 0.2.1, matching package.json and pnpm-lock.yaml. Both READMEs reflect the current composition, and the learning-port comment correctly names Support 0.2.7 and KB 0.1.6.

The added regression test exercises /api/health through createWorker() and compares its package details against the manifest. I checked the…

  • Open findings after this round: 2 (0 bug-severity).

Findings

🟠 Issue 1 — New README storage pin 0.4.7 could not be verified against the manifest

README.md:26 · risk · identified by z-ai/glm-5.3-flash

The diff rewrites the root README's portability exhibit to name four exact composition pins:

the account API composes exact @​pegma/storage-cloudflare-d1@​0.4.7, @​pegma/sessions@​0.2.1, @​pegma/identity@​0.1.2, and @​pegma/authorization-identity@​0.4.0

Three of the four were verified against package.json and are exact matches (@​pegma/sessions → 0.2.1, @​pegma/identity → 0.1.2, @​pegma/authorization-identity → 0.4.0), and the worker/src/index.ts health literals agree with all of them. The storage pin is the one I could not confirm: verification ended before package.json/pnpm-lock.yaml could be grepped for @​pegma/storage-cloudflare-d1, and the only other storage version string in the repo, src/data/recipe-backlog.ts:24, still says 0.4.6.

If the manifest still pins 0.4.6, this line is a fresh instance of exactly the r2-1 failure class (documentation naming a composition the host does not have), introduced by this diff — the pre-diff README named @​pegma/storage-cloudflare-d1 without any version, so the 0.4.7 is newly added text. If an earlier commit in the range bumped the adapter to 0.4.7, the line is correct and this can be closed. Proof gap: the manifest/lockfile state for @​pegma/storage-cloudflare-d1 was not inspected before the tool budget ended; please confirm 0.4.7 against package.json before merge.

🟠 Issue 2 — Sessions bump desynchronizes catalog recipe pins from the green fixture they cite

src/data/recipe-backlog.ts:19 · risk · identified by z-ai/glm-5.3-flash

This PR moves the host and lockfile to @​pegma/sessions@​0.2.1, but the published composition catalog still describes the recipes with the previous version:

  • src/data/recipe-backlog.ts:19 — the green cf-passkey-accounts recipe (P1, fixture status green) pins @​pegma/sessions@​0.2.0.
  • src/data/recipe-backlog.ts:246 — the support-queue-slice recipe pins the same 0.2.0.

The recipe fixtures carry no manifest of their own (recipes/cf-passkey-accounts/ contains only composition.ts and its test), so the CI-tested fixture the catalog cites resolves @​pegma/sessions from the root manifest — now 0.2.1. The catalog data pointing at that fixture still claims 0.2.0, and it is served on /examples and through the MCP recipe tooling.

The drift has functional consequences beyond prose: recipePackagesReady (src/data/catalog-schema.ts:274) requires a recipe's exact pin to equal the npm-latest version, and src/data/mcp-tools.ts:362 filters recipe output on that result. Once Sessions 0.2.1 publishes and becomes npm latest, the green P1 recipe flips to not-ready in catalog/MCP output; if 0.2.1 is already npm-latest, it has flipped already.

What I checked: compile-catalog.test.ts stubs npm lookups, so no test ties recipe pins to the host manifest, and a repo-wide search shows these catalog pins are the only remaining sessions@​0.2.0 strings outside unrelated release-tag fixtures. Proof gap: npm's latest version for @​pegma/sessions is not determinable from the checkout, so I cannot say whether the gate is already false today or flips on publish. Note that other recipe pins drift further (@​pegma/support-desk-application@​0.1.1 at line 250 vs the host's 0.2.7), so if pre-bump pins are intentional for recipes, the pin-equality semantics in recipePackagesReady still need reconciling with that intent.

Workflow run

Comment thread README.md Resolved
@FlyOverCoderKY

Copy link
Copy Markdown
Contributor Author

Fixed the body-only r2-1 finding in c784b16. Health and current composition guidance identify Support0.2.7, KB0.1.6 and Sessions0.2.1. The normal Worker health regression compares all four reported package identities with package.json and caught the superseded versions before the fix.

Both local Node22 and24 gates passed check, build and all1459 tests each, including155 Native D1 cases and2 benchmarks, with zero skips. Current GitHub CI also passed1459 tests. The8 earlier inline threads have fix-SHA replies and are resolved. Current-head OpenRouter review remains the merge gate.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OpenRouter pull-request review

Verdict: clean
Scope: latest-commit (commit-range)
Mode: verify
Commit: 97195a0f15f3ea671c264ccaa01daa4fe02ace77
Judge: openai/gpt-5.6-luna
Cost: $0.0896 (lanes $0.0895 + judge $0.0001)

Lanes

  • openai/gpt-6.1-sol: ok (0 finding(s), 28.0s, 58783+840 tokens (34113 cached), 3 tool round(s), via Azure, $0.0808)
  • z-ai/glm-5.3-flash: ok (0 finding(s), 88.9s, 93350+5313 tokens (65280 cached), 7 tool round(s), via Inceptron, $0.0087)

Round 4 resolution

  • ✅ r3-1 fixed correctly — New README storage pin 0.4.7 could not be verified against the manifest: The README's @​pegma/storage-cloudflare-d1@​0.4.7 pin matches both the exact dependency in package.json and the importer resolution in pnpm-lock.yaml. The new catalog regression also checks the installed adapter identity and README pin against the manifest.
  • ✅ r3-2 fixed correctly — Sessions bump desynchronizes catalog recipe pins from the green fixture they cite: Both cf-passkey-accounts and support-queue-slice now pin @​pegma/sessions@​0.2.1, matching the root manifest and lockfile used by their fixture imports. The Support Desk recipe pins also match the installed 0.2.7 packages. Added regressions check fixture imports, installed package identities, catalog pins, and production-plan rejection of mismatched Sessions publication metadata; the assembl…
  • Open findings after this round: 0 (0 bug-severity).

No structured findings from the successful lane(s).

Workflow run

@FlyOverCoderKY

Copy link
Copy Markdown
Contributor Author

Confirmed r3-1 against the actual current manifest, lock importer and installed package. The D1 dependency is0.4.7 in package.json line47 and pnpm-lock.yaml lines77–79, matching the README. The new compiler regression verifies this metadata against the selected graph. Current OpenRouter round4 confirms both r3 findings resolved. Manifest · Lock importer

The r3-2 fix is in 97195a0. Node22 normal checks, build and all1464 tests passed, with zero skips. Final Node24 and current GitHub CI are completing. Existing merge gates remain required.

@FlyOverCoderKY
FlyOverCoderKY merged commit 94df7f3 into main Nov 12, 2026
2 checks passed
@FlyOverCoderKY
FlyOverCoderKY deleted the codex/pg02-engineering-current-20261111 branch November 12, 2026 02:46
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