Skip to content

fix(update): reduce packages that exceed installed-entry limits - #196418

Closed
roboclaw-bot wants to merge 3 commits into
mainfrom
roboclaw/qo-installed-package-footprint
Closed

roboclaw-bot wants to merge 3 commits into
mainfrom
roboclaw/qo-installed-package-footprint

Conversation

@roboclaw-bot

@roboclaw-bot roboclaw-bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Collaborator

What Problem This Solves

Candidate upgrades can fail because the installed package exceeds the 50,000-entry limit in shipped updaters. A canonical package installation measured 50,644 entries; the release budget is 47,500.

User Impact

This draft targets the unnecessary Doctor restoration graph included in the transcript worker. The exact-head npm 12 install passed the installed entry and byte budgets. Successful upgrades, complete private-worker qualification and causal entry savings remain unestablished. No schema, data, public API, dependency, or updater-limit change is intended.

Why This Change Was Made

Retirement comparison reads import an exact-row query from a Doctor restoration module, retaining an unrelated cold-restoration dependency graph. Move that unchanged query to the existing entry-read owner and migrate its internal consumers. Keep the transcript worker's private graph and lazy task handling; do not delete runtime files or increase limits.

Evidence

  • Rejected baseline: Package Acceptance 42744205431, npm 12 installed-tree check, source 4a474f2: 50,644 entries / 630.1 MiB. Inventory and tarball identities were independently matched. This is not a candidate-after measurement.

  • Reviewed range: original base b8d5978 → current head 8d225de. The four-file correction, reviewed against 164c253, received fresh isolated Codex autoreview P0–P2: scoped-clean, plus parent review. Four-file format/core lint and git diff --check passed. Test bodies and assertions are unchanged; lint/static review are not new-head types/runtime proof.

  • Original exact-head failure: CI 42750218546 checked out 6942a0f, then failed build/types (TS2304) and Doctor SQLite at runtime (ReferenceError): the moved reader lacked its sessionEntrySnapshotColumns import. This was PR-caused and missed by prior review/lint. 164c253f restores the original owner binding; failed old-source evidence remains retained.

  • Historical correction proof at exact 164c253: CI 42753968050 preflight confirms the checkout; build-artifacts, production types, and actual Doctor SQLite suite passed. This establishes the missing-import build/runtime correction at 164c, not 8d head proof, full-graph or installed-budget proof. The original CI runs remain untouched with their other failures/results retained.

  • Further PR-caused cutover failures: 164c test types found stale query imports in agent-create and onboarding; source inspection found the same import in Doctor relative-store tests. 8d225de migrates all three to the one entry-read owner, with no bridge/suppression or test-body change. Both affected test-type leaves now pass on8d, and the corrected absolute-path emission selector has executed successfully.

  • Emission regression: old source6942 failed setup before build because a relative source was compared with the owner’s absolute entry. On exact8d, tooling1/129633783386 records 58 emitted retirement-handler files in Node and Bun; the regression passed in 968ms / 711ms, including the unchanged <1,500 assertion. This measures only the handler under the maintained private config. It does not establish complete transcript output, a controlled baseline reduction, installed entries or savings; headroom is not a baseline measurement. The overall tooling job failed on the distinct npm-authority test below.

  • New-head CI: 42756843472 targets exact 8d225de; preflight129633085752 confirms actual checkout via HEAD and CHECKOUT_SHA. Build129633777094, production types, test types core1, test types core2, and Doctor SQLite129633783308 passed. Other CI failures are retained; these successes do not establish full-package qualification.

  • Additional failures retain UNKNOWN attribution: UI geometry, npm publication authority’s unsettled top-level await, toolchain-repair fixture ENOENT and dependency/deadcode diagnostics. The npm-authority test also failed on8d at npm-preflight-tooling-identity.mjs:563; handler success does not turn that whole job green. These failures are not declared baseline, infrastructure, fixed or ignorable. The old bundle-infra snapshot ReferenceError remains a historical missing-import cascade; no unrelated repair is included.

  • The single remote proof request queued without executing the payload, then was stopped and independently confirmed completed/cancelled. This production host is not qualified for worker builds or package proof. Draft publication follows the repository's unavailable-build-capacity policy; it does not waive the build.

  • Package gate history: at2026-11-10 04:50UTC the build was still active, so no Package Acceptance attempt was made. Fresh05:03 metadata confirms exact8d build and Doctor SQLite SUCCESS. The original no-dispatch decision remains valid history; the newly satisfied build gate admitted one package proof submission.

  • Original Package Acceptance42759743028, attempt1: completed SUCCESS, all selected jobs settled. Resolver129642392441, integrity129648023313, npm12 install129649110328, targeted onboard129651208712, and final verifier129654742326 passed. The original run42759743028 selected source=ref / exact8d and npm-onboard-channel-agent; workflow SHA8bb413e6a3bbeeab7210587f2c16efd7476fa34e remains separate from product source. No rerun or duplicate producer.

  • Onboard positive evidence: small lane artifact13739245492, service ZIP SHA256 edc89d9164e9c36ccaba68be97f0e1e3e88acb17d2cc42e1604f9d377af1a92f, contains the positive npm-tarball onboard/channel/agent completion marker, one 277s attempt, no failures, selected source8d and package-under-test-42759743028-1 binding. The pinned strict harness requires installed CLI/onboarding, channel/status checks, Doctor, a mocked local model turn, and audit execution identity checks before/after Gateway restart before that marker. Individual successful container outputs are suppressed rather than retained; this is source-qualified lane completion, not an independently retained transcript for each inner check. It does not prove live channel/model service behavior or the separate retirement-detect branch.

  • Measured installed budget PASS: the complete npm12-installed-tree-42759743028-1 inventory, artifact13738500162 recounts 45,569 entries / 570,420,586 file bytes (543.995MiB), below 47,500 entries / 900MiB, leaving 1,931 entries of headroom. Context and complete:true record agree with every entry; Node24.22.1/npm12.0.2/linux-x64. ZIP SHA256 dc0436c3786a773f82fc86444422851bc08b28a486916f0220966b6032aad5a4 matches the artifact service digest. The install job also passed installed CLI version and lifecycle-completion checks. The historical 50,644-entry tree is not a controlled same-lock before/after comparison; the observed 5,075-entry difference is not attributed wholly to this PR.

  • Immutable candidate: source 8d225de, version 2026.11.2, tarball openclaw-current.tgz, SHA256 a690ac41495927e8ac8f13ed72a1aabc73c1dbf4d5ea085f1f40ca86ed30ef18. Producer run42759743028/attempt1 uploaded package-under-test-42759743028-1, artifact13737437844, service ZIP digest 871cf3bb80c0c38cdae9d51b852f5f8a0238a7b6c8a23c72c5414c2d44240546. Resolver output, the successful integrity hash check and inventory bind these identities; archive service digest and tarball digest are distinct.

  • Same-tarball cold/history proof: Package Acceptance42763095755, attempt1 completed SUCCESS, including session-runtime-context129657370117 and final verifier129660178867. The single source=artifact request reused the complete original tuple above, with no source package rebuild or registry/image publication. Resolver, integrity and npm12 acceptance passed. Workflow SHA179529ec9dd83b98872ccf056cc8135adb642c06 remains separate from product8d. The verified required-contract admission artifact13738961753, service ZIP SHA256 8f7bb4f5838140cf3adab843cbac667333b575929166a477a5c8a9b67094eccb, binds exact8d/package hash and admits cold storage required, SQLite repair and producer-fragment runtime context, with scenario omissions disabled. The verified lane data artifact13738669832, service ZIP SHA256 6aac4023637e7a8fb37c9927415271060e02ec9103e85d069b7f5706d8b4808e, records the installed functional image, maintained command, positive OK and one 169s successful attempt. Runtime alias artifact13739080704 binds the same source8d/version2026.11.2/tarball SHA256a690ac41495927e8ac8f13ed72a1aabc73c1dbf4d5ea085f1f40ca86ed30ef18. The pinned strict harness requires runtime-context checks followed by cold archival/history, restart and recovered-state assertions before OK; this is source-qualified required-lane completion. Successful inner phase output is redirected to a temporary log and deleted, so independent per-phase positive markers are not retained. This covers the required cold/history request paths, not every private-worker branch, the retirement-detect request or a controlled full-graph emission comparison.

  • Exact8d source CI 42756843472 is now terminal FAILURE:265 jobs,229 success,24 failure,one cancelled,11 skipped; zero pending. The original 22 failed jobs now have exact-head case/diagnostic evidence, including UI locator/geometry, tooling, Gateway lifecycle, context admission, provider-auth and static dependency failures. Some complete UI case labels remain redacted; assertions/code frames are retained. All baseline/PR attribution remains UNKNOWN without qualified equivalent main execution; no failure waiver or full-CI success. Additional terminal iOS lifecycle129633777538 failed its focused simulator step; its raw case log remains unread. CI gate129668845155 failed selected-lane verification. The ready-PR-event-only failure reporter was skipped for this manual draft run; authoritative compact-main mapping remains unavailable. Previously inspected main42762110071, source6b4ef49c0927951bbd5982f86fac2ba41d5e02ba, is not a matching-signature witness. Unchanged blobs, job names and Node/Bun asymmetry do not establish baseline.

  • Before readiness: remaining required CI/review and unknown-failure investigation; controlled baseline/candidate full private transcript emission comparison; controlled BEFORE/AFTER complete installed-tree comparison; separate same-tarball retirement-detect requests with exact source/build/package/artifact custody. The required cold/history lane has now completed as scoped above, with its per-phase output-retention limit recorded. The original selected Package Acceptance profile and candidate npm12 installed budget are verified above. No causal package savings, successful old-updater upgrade or complete private-worker qualification is claimed. The PR remains a draft.

Requested by @steipete; contributor credit is retained in the commit.

Work sessions

Linked for team reference; these sessions aren’t public.

Move the exact canonical-repair query into the entry-read owner so transcript retirement reads do not import Doctor restoration. Preserve query behavior and migrate internal consumers. Add a real private-build emission regression; remote emission and installed-package proof remain pending.

Co-authored-by: steipete <[email protected]>
@clawsweeper

clawsweeper Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 10, 2026
roboclaw-bot and others added 2 commits November 10, 2026 03:53
Restore the owner import omitted when moving the canonical repair reader. The missing binding caused TS2304 in declaration builds and ReferenceError during Doctor SQLite recovery. Existing retirement and recovery query tests cover this path; corrected runtime and typecheck proof remain pending CI.

Co-authored-by: steipete <[email protected]>
@openclaw-barnacle openclaw-barnacle Bot added commands Command implementations agents Agent runtime and tooling labels Nov 10, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 10, 2026
@clawsweeper

clawsweeper Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR moves an unchanged session-row query into the existing entry-read owner so retirement reads avoid importing Doctor restoration dependencies.

Example: Building a candidate package for an updater with a 50,000-entry limit.

  • Before: The reported baseline installed tree contains 50,644 entries and exceeds the limit.
  • After: Retirement reads use the smaller dependency path; the complete candidate installed-entry count remains unestablished.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The focused refactor appears correct and useful; demonstrated coverage reaches the build harness rather than the complete installed-package outcome.
Proof confidence 🦐 gold shrimp (3/6) Real behavior proof is not required for maintainer- or bot-authored pull requests.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Older shipped updaters can reject candidate packages whose installed trees exceed their fixed entry limit.
Reason: The maintainer-authored direction addresses an observed package acceptance failure through a narrow dependency cleanup without changing updater limits or user behavior.

Merge readiness

✅ Ready for maintainer review

Keep open: this maintainer-authored draft addresses a concrete package-budget failure, and the focused ownership move is not present on current main.

Priority: P2
Reviewed head: 8d225de68284096f4f0fd6ac06db8551fcfff1f0

Before merge

None.

Findings

None.

Tests

  • Missing end-to-end proof: The supplied evidence does not yet show a controlled baseline failure at the emission assertion, complete-package savings, or installed CLI/private-worker behavior and a latest-stable upgrade with settings and data intact.
Agent review details

How this fits together

The private transcript worker handles retirement comparison requests by reading session claims from SQLite; its imported dependencies also contribute files to the installed package.

flowchart TD
 A[Private transcript worker] --> B[Retirement reader]
 B --> C[Migration claim reader]
 C --> D[Entry read owner]
 D --> E[SQLite session rows]
 A --> F[Packaged worker graph]
Loading

Technical review

Best possible solution:

Keep the unchanged query in the existing read owner and qualify the resulting package against the unchanged installed-tree budget.

Do we have a high-confidence way to reproduce the issue?

Source establishes the unnecessary Doctor dependency path, and the linked baseline acceptance job confirms an installed-tree budget failure; no reproduction was executed during this read-only review.

Is this the best way to solve the issue?

The patch uses the existing entry-read owner, preserves the specialized query contract, updates its consumers, and removes the old export without adding runtime machinery.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 21f17afce911.

Provenance checked

  • Exact session-row repair reader keeps the original intent (cd8a964: Doctor needed an exact persisted-row probe for canonical-key repair without runtime alias reconciliation.)
  • Lifecycle repair consumer keeps the original intent (26dffe7: Retention and continuation cleanup moved through the existing worker and synchronous lifecycle transaction owners.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit 26dffe7 adds src/config/sessions/session-accessor.sqlite-projection-state.ts:42 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 26dffe7468cd; files: src/config/sessions/session-accessor.sqlite-projection-state.ts)
  • Dallin Romney: Raw commit eaa8aeb adds test/scripts/tsdown-config.test.ts:297 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: medium; commits: eaa8aebfb693; files: test/scripts/tsdown-config.test.ts)

PR surface

Source 0, Tests +33, Other +2. Total +35 across 13 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 5 54 54 0
Tests 7 39 6 +33
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 1 2 0 +2
Total 13 95 60 +35

Preflight source

Source unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified.

Review metrics

Metric Value Why it matters
Production versus test growth Production net 0 lines; tests net +33 lines Production changes relocate existing logic; the added build regression protects the private-worker dependency footprint.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: This is a focused candidate-package compatibility repair with an observed acceptance failure, without evidence that a published release currently breaks ordinary upgrades.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Complete the package and upgrade evidence identified in realBehaviorProof.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed November 10, 2026, 12:22 AM ET / 05:22 UTC.

@steipete

Copy link
Copy Markdown
Contributor

Coordination note from the daily update-reliability sweep: current main is now over the 50,000-entry cap that published updaters enforce. An npm 12 install of main 5426184 measured 50,924 entries, and published 2026.9.9 and 2026.9.36 updaters refuse it with "Package rollback verification entry limit exceeded" (both passed the day before).

This draft has not moved since 04:24Z and is waiting on maintainer review, so to unblock main I am carrying the same change (unchanged code, all three commits) onto current main as a separate branch, codex/issue-196079-worker-footprint, with RoboClaw credited as co-author. I will measure the installed tree on current main with the fix and run the 9.9 and 9.36 updater lanes before opening it. If this draft lands first, I will drop mine.

steipete added a commit that referenced this pull request Nov 11, 2026
…entry budget (#197269)

* ci(update): enforce the installed-tree budget in the published-driver cell

The 47,500-entry budget check only ran in Package Acceptance, which main never
reached on a schedule (Update Migration is blocked at image prep), and the
hourly published-driver cell uses the latest published driver, which degrades
past the walk cap instead of refusing. So #196079 pushed main past the 50,000
entries that 2026.9.x updaters enforce without any CI going red.

Measure the tree the published driver actually installed and assert the same
release budget, so scheduled main validation goes red within the hour.

Refs #196079

* test(sessions): bound the retirement-read worker build

#196079 let the transcript worker's private build reach Doctor's cold-restore
graph, which pushed the installed package past the 50,000 entries that
2026.9.x updaters accept; #197153 fixed the import edge. Build the
retirement-read worker with its real private config and require it to stay
small, so the edge cannot come back unnoticed: 5,408 emitted files before
#197153, 58 after.

Refs #196079
Refs #196418

* ci(update): mount the installed-tree budget module in the Docker harness

The published-driver cell imports scripts/check-openclaw-installed-package-budget.mts,
which the harness did not mount, so the cell would fail on import.
@steipete

Copy link
Copy Markdown
Contributor

Follow-up from the update-reliability sweep. The root-cause change in this draft has landed on main through #197153 (merge 6d71e65, not yet in a release tag), which moves the exact-row reader out of the Doctor repair module, so this draft is superseded. Thank you, RoboClaw: the regression test from this draft (the retirement-read worker build bound) landed separately in #197269 (d3942b5) with RoboClaw credited as co-author, together with a CI guard that fails scheduled main validation when the installed package exceeds the updater entry budget.

Measured on current main with npm 12: 45,856 installed entries (budget 47,500), and a published 2026.9.36 updater now updates to it cleanly. Before the fix, 2026.9.9 and 2026.9.36 refused main at 50,927 entries. I have not closed or edited this draft; that is left to its owner.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 12, 2026
…entry budget (openclaw#197269)

* ci(update): enforce the installed-tree budget in the published-driver cell

The 47,500-entry budget check only ran in Package Acceptance, which main never
reached on a schedule (Update Migration is blocked at image prep), and the
hourly published-driver cell uses the latest published driver, which degrades
past the walk cap instead of refusing. So openclaw#196079 pushed main past the 50,000
entries that 2026.9.x updaters enforce without any CI going red.

Measure the tree the published driver actually installed and assert the same
release budget, so scheduled main validation goes red within the hour.

Refs openclaw#196079

* test(sessions): bound the retirement-read worker build

openclaw#196079 let the transcript worker's private build reach Doctor's cold-restore
graph, which pushed the installed package past the 50,000 entries that
2026.9.x updaters accept; openclaw#197153 fixed the import edge. Build the
retirement-read worker with its real private config and require it to stay
small, so the edge cannot come back unnoticed: 5,408 emitted files before
openclaw#197153, 58 after.

Refs openclaw#196079
Refs openclaw#196418

* ci(update): mount the installed-tree budget module in the Docker harness

The published-driver cell imports scripts/check-openclaw-installed-package-budget.mts,
which the harness did not mount, so the cell would fail on import.
@RomneyDa

Copy link
Copy Markdown
Member

Superseded by #197153 (transcript-worker import isolation) and #197269 (installed-package entry-budget regression coverage), both merged. Closing this duplicate implementation; release applicability is tracked against those canonical changes.

@RomneyDa RomneyDa closed this Nov 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling commands Command implementations P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: S status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants