Skip to content

refactor: localize private login, evidence, and transport phases - #179048

Merged
steipete merged 3 commits into
mainfrom
deslop/z25-73-private-auth-phases-20261015
Oct 21, 2026
Merged

steipete merged 3 commits into
mainfrom
deslop/z25-73-private-auth-phases-20261015

Conversation

@steipete

@steipete steipete commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Private login, evidence, transport and rendering phases carry one-consumer helpers and argument envelopes that duplicate facts already owned by their callers.

User Impact

No intended user-visible change. Authentication, approval matching and settlement, provider requests, Slack duplicate-send protection, evidence containment and memory-wiki publication remain intact. No migration or operator action is needed.

Why This Change Was Made

Localize private phases in their existing owners and fold the sole-consumer WhatsApp approval module into its scenario runner. Remove orphan functions and types rather than retaining test-only production seams. The participant-routing test now exercises the public scenario entry point with its original reaction assertion.

The complete cut removes 555 net production lines across 12 production paths, excluding tests and the shrink-only assertion baseline. Shared exports, public SDK/config/CLI/protocol contracts, lazy imports, security checks, durability and realistic concurrency protections stay.

Best-effort tradeoffs accepted

  • Static-key Vertex requests no longer yield through an empty asynchronous header wrapper. Source inspection shows no authority check or effect relies on this scheduling gap; real ADC authorization still awaits. Authentication, header capture order and request protections remain.
  • No defensive guard is removed. The approval lower-bound absence branch disappears only where the runner supplies its own mandatory local new Date; the general optional observation bound remains supported.

Evidence

The login/adoption packet passed 123 focused tests across 12 files; gallery/wiki passed 36 owner tests across six files and two selected HTTP evidence/UTF-8 cases. Both packets passed targeted native types, typed lint, formatting and line caps. Complete-branch independent review found no actionable P0-P2 defects.

The final ten owner suites passed all 273 tests in a serial single-worker run (726 seconds wall time under host load); eight selected Slack finalization sibling cases passed in 169 seconds. The changed WhatsApp scenario suite ran within the four-file QA group (169 seconds, mostly transformation/import overhead). Targeted native types and formatting passed. Assertion-safety, mock-export, session-accessor and line-cap checks passed, along with 14 lint-suppression and four selected wrapper/eager-import closure cases. Runtime cycles: zero. Static cycles: zero.

No broad local build, whole-graph typecheck, live provider or live channel proof is claimed. Hosted CI on the exact pushed head is the broad gate.

Local typed lint reports ten Google SDK error-type annotation diagnostics. A serial clean-checkout reproduction using the identical original owner blob reports the same annotations (15 before this cut, ten remaining). Targeted native typechecking passes; no suppression or cast was added to conceal the local lint limitation. This is not a classification of hosted CI.

Conflict-only rebase: main removed an obsolete WhatsApp test injection and import; this branch keeps that removal alongside the public approval regression. The rebased head passed 45 WhatsApp tests across two files, targeted native types, typed lint of the conflicted file, formatting, 14 lint-suppression tests, and both cycle checks (zero). The previous head's successful CI run 39548903903 is prior-head evidence only; current-head CI remains the broad landing gate.

@clawsweeper

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

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Codex Review Summary

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

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-21T07:00:30.532549Z 07e05b4 New commits
ℹ️ 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.

@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. 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 21, 2026
@clawsweeper

clawsweeper Bot commented Oct 21, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR moves private login, adoption, evidence, rendering, and transport helpers into their existing callers and removes obsolete interfaces.

Example: WhatsApp group approval prompt approval-message-1 comes from participant 999@lid in [email protected].

  • Before: The separate approval module sends 👍 to that message with participant 999@lid.
  • After: The scenario runner sends the same reaction with the same participant coordinates.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The patch is coherent and has passing exact-head validation; confidence in behavioral equivalence rests on source review and owner tests rather than shipped-entry-point proof.
Proof confidence 🦐 gold shrimp (3/6) This maintainer-authored refactor is outside the ordinary contributor proof gate; its supplied evidence is owner-test and CI validation, with no live execution claimed and no material authority-contract change identified.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Refactor · Worth it: Yes
Reason: The maintainer-approved direction removes redundant private plumbing while retaining public behavior and established ownership.

Merge readiness

✅ Ready for maintainer review

Keep this PR open: it is useful maintainer-directed cleanup, preserves the reviewed contracts, and has no actionable findings; the exact-head CI gate passes.

Priority: P3
Reviewed head: 5935ab3aac6b5ac1166d287af40668cd109fad96

Before merge

None.

Findings

None.

Tests

  • Missing end-to-end proof: Supplied validation covers owner tests and CI rather than live login, provider, or channel execution.
Agent review details

How this fits together

CLI login, session continuation, channel finalization, and QA entry points consume provider results, thread metadata, messages, and evidence files to produce credentials, session bindings, requests, and reports.

flowchart TD
  A[CLI and Gateway callers] --> B[Login and adoption owners]
  B --> C[Credential and session stores]
  D[Agent and channel dispatch] --> E[Google and Slack transports]
  F[QA scenarios and evidence files] --> G[Scenario and artifact owners]
  G --> H[Reports and gallery responses]
Loading

Technical review

Best possible solution:

Retain the localized implementations with their existing authority, persistence, containment, and transport contracts.

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

This PR claims a behavior-preserving refactor rather than a reproducible product bug; source comparison supports that scope.

Is this the best way to solve the issue?

The change uses existing owners, removes the replaced private paths, and preserves distinct lifecycle and security checks without adding competing machinery.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 54b5607e5584.

Provenance checked

  • Codex local adoption keeps the original intent (7862a5d: Keep local continuation specialized so generation restoration and upstream baselining occur inside a pinned exclusive operation.)
  • Provider login persistence and model activation keeps the original intent (b342541: Separate provider login from model activation and preserve existing model choices unless explicitly requested.)
  • Gallery artifact access keeps the original intent (c677424: Expose declared QA artifacts through contained server routes without exposing arbitrary repository files.)
  • Slack desktop artifact validation keeps the original intent (28ae31a: Derive each verdict from its own staged artifacts and require matching approval interaction identities.)
  • Google Vertex header scheduling changes intended behavior with a stated reason (0b59964: Support asynchronous authorized_user ADC credentials; this PR explicitly explains removing only the empty async hop for static keys.)
  • Slack preview finalization keeps the original intent (eee37bf: Read back ambiguous edits before allowing a duplicate fallback reply.)
  • Wiki rendering and related blocks keeps the original intent (3059702: Render people metadata and relationships while maintaining generated-page links and managed content.)
  • WhatsApp approval orchestration keeps the original intent (11cd600: Split the live runtime along private responsibilities while preserving scenario behavior; the current change reunites its sole-consumer approval phase with the scenario owner.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit e2da41f adds extensions/codex/src/session-catalog-adoption.ts:46 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: e2da41f079fe; files: extensions/codex/src/session-catalog-adoption.ts)
  • Vincent Koc: Raw commit 69216f1 adds extensions/qa-lab/src/evidence-gallery.ts:406 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 69216f17455d; files: extensions/qa-lab/src/evidence-gallery.ts)
  • Colin Johnson: Raw commit c677424 adds extensions/qa-lab/src/evidence-gallery.ts:72 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: c677424edba0; files: extensions/qa-lab/src/evidence-gallery.ts)

PR surface

Source -555, Tests +23, Other 0. Total -532 across 15 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 12 1283 1838 -555
Tests 2 84 61 +23
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 1 1 1 0
Total 15 1368 1900 -532

Review metrics

Metric Value Why it matters
Production versus test LOC Production +1283/-1838; tests +84/-61 The net production reduction is 555 lines; test growth moves existing participant-routing coverage to the public scenario entry point.

Labels

Label changes:

  • add P3: This is internal maintenance with no intended user-visible behavior change or urgent defect.
  • 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:

  • P3: This is internal maintenance with no intended user-visible behavior change or urgent defect.
  • 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 21, 2026, 1:38 AM ET / 05:38 UTC.

@steipete
steipete force-pushed the deslop/z25-73-private-auth-phases-20261015 branch from 5935ab3 to 07e05b4 Compare October 21, 2026 06:27
@steipete
steipete merged commit a780016 into main Oct 21, 2026
133 checks passed
@steipete
steipete deleted the deslop/z25-73-private-auth-phases-20261015 branch October 21, 2026 07:07
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

steipete added a commit that referenced this pull request Oct 21, 2026
Keep live local types and protocol enrichment private, delete unused wiki aliases and the uncalled cron-history test helper, and move test-only WhatsApp metadata into its fixture.

The lost-consumer audit follows #179048, #179101, #179127, #179149 and #179180. Register the development-loop benchmark documented and invoked by #179175 as a real Knip entrypoint.

Proof: all three deadcode wrappers pass at base 5ceb735; 231 focused tests pass with one worker; targeted typecheck, lint, format and independent P2 review pass. Subsequent main changes do not overlap the repair.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 22, 2026
…nclaw#179048)

* refactor(auth): localize private login and adoption phases

* refactor(qa): localize gallery and wiki render phases

* refactor(transports): localize private request and approval phases
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 22, 2026
Keep live local types and protocol enrichment private, delete unused wiki aliases and the uncalled cron-history test helper, and move test-only WhatsApp metadata into its fixture.

The lost-consumer audit follows openclaw#179048, openclaw#179101, openclaw#179127, openclaw#179149 and openclaw#179180. Register the development-loop benchmark documented and invoked by openclaw#179175 as a real Knip entrypoint.

Proof: all three deadcode wrappers pass at base 8a4943d; 231 focused tests pass with one worker; targeted typecheck, lint, format and independent P2 review pass. Subsequent main changes do not overlap the repair.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

channel: slack Channel integration: slack commands Command implementations extensions: codex extensions: google extensions: memory-wiki extensions: qa-lab P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: XL 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