Skip to content

fix: restore unique PR wrapper extraction inventory - #169547

Merged
obviyus merged 1 commit into
mainfrom
fix/eager-import-closure-dupes
Oct 12, 2026
Merged

obviyus merged 1 commit into
mainfrom
fix/eager-import-closure-dupes

Conversation

@obviyus

@obviyus obviyus commented Oct 12, 2026 •

Copy link
Copy Markdown
Collaborator

What Problem This Solves

Fixes the PR wrapper extraction regression that makes test/scripts/eager-import-closure.test.ts fail on main.

User Impact

No application behavior changes. The trusted wrapper still extracts the same source files, once each.

Why This Change Was Made

Commit be2850e (#168199) added three inventory entries already introduced by cbc2017 (#169327): src/chat/sender-identity.ts, src/sessions/input-provenance.ts, and src/sessions/user-turn-transcript.metadata.ts. copyPrWrapperSources faithfully copies and returns this production inventory; this is duplicate inventory data, not alias resolution or a graph traversal defect.

Remove the three newly added duplicate lines while retaining their existing entries. The parent of #168199 has no duplicate inventory lines; that commit has exactly these three. The existing uniqueness assertion and extracted runtime-closure tests remain unchanged.

Evidence

Command: node scripts/run-vitest.mjs run test/scripts/eager-import-closure.test.ts

  • Before, on fetched origin/main 6ce48cb: 1 failed, 16 passed (17). The failing case is resolves wrapper package exports and workspace aliases from the extracted dependency context, at line 173; received the three duplicate paths above instead of []. This newer main reproduces one failure, not the three previously reported at 52200cf.
  • After: 17 passed (17), including inventory closure, extracted dependency resolution, wrapper lease bootstrap, and legacy anchor cases.
  • git diff --check: passed.
  • oxfmt --check --no-error-on-unmatched-pattern scripts/pr-lib/wrapper-components.txt: exited successfully; plain-text inventory is not a supported formatting target (0 files).
  • check-changed --dry-run identifies the tooling lane. No TypeScript or JavaScript changed, so oxlint and tsgo do not have an applicable changed source target.
  • Searched open PRs for eager-import closure and wrapper duplication; found no existing fix for these three duplicate entries.

Two-way door: reverting restores only the duplicate inventory entries. Blast radius is limited to PR wrapper extraction and its tests; no schema, stored state, configuration, or public API changes.

@clawsweeper

clawsweeper Bot commented Oct 12, 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.

@obviyus
obviyus marked this pull request as ready for review October 12, 2026 02:40
@openclaw-barnacle openclaw-barnacle Bot added scripts Repository scripts size: XS labels Oct 12, 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. labels Oct 12, 2026
@clawsweeper

clawsweeper Bot commented Oct 12, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

Removes three duplicate paths from the trusted PR wrapper extraction inventory.

Example: The extraction test reads src/chat/sender-identity.ts and the two duplicated session metadata paths.

  • Before: Each path appears twice, causing the inventory uniqueness assertion to fail.
  • After: Each path appears once, preserving source coverage and satisfying the existing assertion.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The patch is focused and correct; supplied execution evidence is an extraction-test report rather than a recorded full wrapper operation.
Proof confidence 🦐 gold shrimp (3/6) This collaborator-authored inventory repair is outside the ordinary contributor proof gate; supplied validation reports the unchanged extraction suite passing after the fix.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Maintainer extraction checks fail because the production wrapper inventory lists three source files twice.
Reason: The collaborator-authored repair restores an existing invariant with three deletions and no change to extracted capabilities.

Regression provenance

Regression provenance — verified: source commit be2850e6d25e by Peter Steinberger; canonical PR #168199 (blame-to-merge-commit).

Merge readiness

✅ Ready for maintainer review

Keep open: this PR fixes a current-main inventory defect while preserving every extracted source path; no actionable correctness or security findings.

Priority: P2
Reviewed head: 09deb4b3b5e23222aa7e1e4c15d549a74fc1f027

Before merge

None.

Findings

None.

Agent review details

How this fits together

The PR wrapper reads a source inventory to select trusted repository files for isolated extraction; extraction tests consume that same inventory and check dependency closure.

flowchart LR
  A[Trusted repository revision] --> B[Wrapper source inventory]
  B --> C[PR wrapper extraction]
  C --> D[Verified extracted sources]
  B --> E[Extraction regression tests]
  D --> F[PR operations]
Loading

Technical review

Best possible solution:

Land the focused inventory repair while retaining the existing uniqueness and extracted dependency-closure checks.

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

Current-main inventory contains the three repeated paths, and the unchanged test explicitly rejects them; the PR also supplies a matching before-and-after test report.

Is this the best way to solve the issue?

Removing duplicate inventory data fixes its producer directly and preserves the complete extracted file set without adding deduplication machinery or weakening coverage.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 734d5b57f146.

Provenance checked

  • Trusted PR wrapper inventory keeps the original intent (be2850e: The agent-deletion change expanded the wrapper dependency inventory, repeating three entries already included by the preceding session-actor change.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit cbc2017 adds scripts/pr-lib/wrapper-components.txt:2145 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: cbc201727b66; files: scripts/pr-lib/wrapper-components.txt)

PR surface

Other -3. Total -3 across 1 file. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 0 0 0 0
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 1 0 3 -3
Total 1 0 3 -3

Labels

Label changes:

  • add P2: A deterministic tooling regression fails an existing extraction test, with no application-runtime impact established.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Label justifications:

  • P2: A deterministic tooling regression fails an existing extraction test, with no application-runtime impact established.
  • 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.

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 October 11, 2026, 10:45 PM ET / October 12, 2026, 02:45 UTC.

@obviyus
obviyus merged commit 21a7e7b into main Oct 12, 2026
162 checks passed
@obviyus
obviyus deleted the fix/eager-import-closure-dupes branch October 12, 2026 02:54
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 12, 2026
## What Problem This Solves

Fixes the PR wrapper extraction regression that makes `test/scripts/eager-import-closure.test.ts` fail on main.

## User Impact

No application behavior changes. The trusted wrapper still extracts the same source files, once each.

## Why This Change Was Made

Commit f99ca39 (openclaw#168199) added three inventory entries already introduced by 4700877 (openclaw#169327): `src/chat/sender-identity.ts`, `src/sessions/input-provenance.ts`, and `src/sessions/user-turn-transcript.metadata.ts`. `copyPrWrapperSources` faithfully copies and returns this production inventory; this is duplicate inventory data, not alias resolution or a graph traversal defect.

Remove the three newly added duplicate lines while retaining their existing entries. The parent of openclaw#168199 has no duplicate inventory lines; that commit has exactly these three. The existing uniqueness assertion and extracted runtime-closure tests remain unchanged.

No overlap with Pash/Sarah changes.

## Evidence

Command: `node scripts/run-vitest.mjs run test/scripts/eager-import-closure.test.ts`

- Before, on fetched `origin/main` 375d62b: **1 failed, 16 passed (17)**. The failing case is `resolves wrapper package exports and workspace aliases from the extracted dependency context`, at line 173; received the three duplicate paths above instead of `[]`. This newer main reproduces one failure, not the three previously reported at 7816f57.
- After: **17 passed (17)**, including inventory closure, extracted dependency resolution, wrapper lease bootstrap, and legacy anchor cases.
- `git diff --check`: passed.
- `oxfmt --check --no-error-on-unmatched-pattern scripts/pr-lib/wrapper-components.txt`: exited successfully; plain-text inventory is not a supported formatting target (0 files).
- `check-changed --dry-run` identifies the tooling lane. No TypeScript or JavaScript changed, so oxlint and tsgo do not have an applicable changed source target.
- Searched open PRs for eager-import closure and wrapper duplication; found no existing fix for these three duplicate entries.

Two-way door: reverting restores only the duplicate inventory entries. Blast radius is limited to PR wrapper extraction and its tests; no schema, stored state, configuration, or public API changes.

Co-authored-by: Ayaan Zaidi <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. scripts Repository scripts size: XS 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.

1 participant