Repository navigation
refactor(config): consolidate session and channel regression fixtures - #114459
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed August 3, 2026, 2:29 AM ET / 06:29 UTC. ClawSweeper reviewWhat this changesThis PR replaces repeated configuration, session, channel, and validation test fixtures with shared helpers and parameterized cases, plus adds regression coverage for scope-key matching and compressed archive cache behavior. Merge readiness⛔ Blocked until real behavior proof is added - 4 items remain Keep this PR open for human handling: it has the protected Priority: P3 Review scores
Verification
How this fits togetherOpenClaw configuration tests exercise group-scope policy, plugin/channel configuration, and session-storage lifecycle behavior. They feed regression protection for the configuration runtime and its SQLite-backed session subsystem, rather than changing user-facing runtime behavior directly. flowchart LR
ConfigInputs[Configuration inputs] --> ScopePolicy[Group scope policy]
ConfigInputs --> ChannelRules[Channel and plugin validation]
SessionData[Session and archive state] --> SessionOwners[SQLite-backed session lifecycle]
ScopePolicy --> RegressionTests[Configuration regression tests]
ChannelRules --> RegressionTests
SessionOwners --> RegressionTests
RegressionTests --> CI[Validation and release confidence]
Decision needed
Why: The post-head rewrite changes the owner boundaries and test structure across every touched file, so automation cannot safely decide whether the older consolidation remains a net simplification. Before merge
Agent review detailsSecurityNone. PR surfaceTests -340. Total -340 across 7 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Rebuild this as a narrow current-main test-only update: preserve only regression cases that the rewritten owners do not already cover, use the canonical SQLite/session test seams, and attach redacted exact-head validation output after the rebase. Do we have a high-confidence way to reproduce the issue? Not applicable: this PR is a test-suite refactor and regression-coverage proposal, not a report of a standalone user-visible failure. Source inspection does establish that its original test-owner structure no longer matches current main. Is this the best way to solve the issue? No, not unchanged: the original fixture consolidation targets pre-rewrite test owners, while current main has a newer SQLite-backed session architecture. The best path is a selective current-main port rather than applying the old branch wholesale. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against b65cc592cc07. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (8 earlier review cycles)
|
6c3e932 to
6d32ea1
Compare
|
@clawsweeper re-review |
|
🦞👀 Command router queued. I will update this comment with the next step. |
|
Merged via squash.
|
What Problem This Solves
Current configuration-owner tests still repeated the same external-catalog, delivery-route, maintenance-admission, and schema-owner fixtures. The SQLite-era suite also lacked direct coverage for exact scope identity, staged archive decoding, and compressed-cache invalidation after source deletion.
Why This Change Was Made
Rebuild only the still-current consolidation on
main: keep helpers and named tables local to the configuration/runtime-config lane, preserve every current case and assertion, and add the three distinct owner-level regressions. The obsolete file-era parent-fork refactor is deliberately excluded after the SQLite ownership rewrite.Production already implements the three covered behaviors. This is a test-correctness and maintenance repair, not a runtime behavior change.
User Impact
No shipped behavior changes. Maintainers retain all current configuration, session-maintenance, archive, delivery, and heartbeat coverage, gain three direct regression cases, and maintain 157 fewer lines of test code.
Evidence
node scripts/run-vitest.mjs src/config/group-scope-tree.test.ts src/config/plugin-auto-enable.channels.test.ts src/config/sessions/archive-compression.test.ts src/config/sessions/delivery-info.test.ts src/config/sessions/store.pruning.test.ts src/config/validation.channel-metadata.test.ts— 6 files passed, 160 tests passed; wrapper passed in 6.23s.0/3; candidate3/3.node scripts/check-changed.mjs— passed on Blacksmith Testbox with core-test typecheck, formatting, 245-rule lint, dependency/boundary guards, and zero warnings or errors. Testbox leasetbx_01kzk3f981sk7w678ayc3tfvfy; Actions run.git diff --check— passed.+0/-0, tests+160/-317(net-157).ClawSweeper rank-up moves are addressed: the change was recreated against the current SQLite-backed owners, redundant old parent-fork fixture edits were discarded, and exact-head focused/Testbox evidence is linked above.