Repository navigation
Conversation
|
Codex review: found issues before merge. Reviewed June 30, 2026, 7:53 AM ET / 11:53 UTC. Summary PR surface: Source +87, Tests +267. Total +354 across 5 files. Reproducibility: yes. Source inspection shows generated provider Review metrics: 1 noteworthy metric.
Root-cause cluster Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Risk before merge
Maintainer options:
Next step before merge
Security Review findings
Review detailsBest possible solution: Rework the fix on current main so generated catalog validation metadata stays separate from runtime request auth, sanitizes both root and plugin-owned catalog writes, and has explicit upgrade behavior for existing plaintext-only Do we have a high-confidence way to reproduce the issue? Yes. Source inspection shows generated provider Is this the best way to solve the issue? No. The redaction goal is right, but writing a generic managed marker into the runtime Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 6cb82eaab865. Label changesLabel justifications:
Evidence reviewedPR surface: Source +87, Tests +267. Total +354 across 5 files. View PR surface stats
Security concerns:
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
|
ClawSweeper PR egg ✨ Hatched: 🥚 common Gilded Test Hopper Hatch commandComment Hatchability rules:
Rarity: 🥚 common. What is this egg doing here?
|
Real behavior proofI re-verified the affected serialization boundary locally after this patch. Scenario checkedThe regression coverage exercises the
Relevant assertions in expect(parsed.providers?.custom?.apiKey).toBeUndefined();
expect(plan.contents).not.toContain("sk-config-plaintext");Commands runObserved result
I used only fake test keys in this verification; no real provider credentials were used or exposed. |
454c048 to
dd10217
Compare
Update: preserve models.json auth contractPushed What changed:
Validation run locally: All commands completed successfully. @clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
@clawsweeper re-review |
Update: normalize source provider ownership before redactionPushed What changed:
Validation run locally: All commands completed successfully. @clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Thanks for the careful work and follow-up tests here. We’re consolidating the #11829 Layer 1 design in maintainer-owned #87166, which is intentionally waiting for the PI-removal work so validation metadata can be separated from runtime request auth. This branch now conflicts with current main, predates the root plus plugin-owned catalog split, and its managed marker can still flow through the current registry’s |
Summary
openclaw-managedapiKey marker instead of deleting the field.Refs #11829.
Real behavior proof
Behavior or issue addressed: After the fix, a source-configured custom provider with a plaintext API key generates
models.jsonwithout that plaintext key, while still keeping a non-emptyapiKeymarker so pi-coding-agent accepts the custom provider and model.Real environment tested: Local Windows development checkout, commit
dd10217e; temporary real OpenClaw agentDir underC:\Users\Lenovo\AppData\Local\Temp; actualplanOpenClawModelsJsonWithDeps,discoverAuthStorage, anddiscoverModelswere executed vianode --import tsx --input-type=module. The credential value was a fake redacted proof key, not a real provider secret.Exact steps or command run after this patch:
models.jsonfor a customopenai-completionsprovider whose source config contained fake plaintextapiKey: sk-live-proof-redacted.models.json.discoverAuthStorageanddiscoverModels.provider.apiKeyserialized to, whether registry parsing failed, and whether the custom model was available.Evidence after fix: Copied live terminal output from the command above:
Observed result after fix: The plaintext key was not serialized; generated
models.jsonusedapiKey: openclaw-managed; pi-coding-agent reported no registry error;custom/custom-modelwas found and available.What was not tested: No live external provider request was made with a real API key. The proof validates the changed persistence/registry boundary using actual OpenClaw planner and registry code with a fake proof key; supplemental tests/typechecks cover the code paths in CI-friendly form.
Verification
npm exec --yes [email protected] -- exec vitest run --config test/vitest/vitest.agents.config.ts src/agents/models-config.applies-config-env-vars.test.ts src/agents/models-config.merge.test.ts src/agents/models-config.providers.auth-provenance.test.ts src/agents/model-auth-markers.test.ts src/agents/pi-model-discovery.test.tsnpm exec --yes [email protected] -- tsgo:testnpm exec --yes [email protected] -- tsgo:coregit diff --checkResult: targeted Vitest run passed 5 files / 43 tests,
tsgo:testpassed,tsgo:corepassed, andgit diff --checkpassed.Security Impact
This reduces token persistence for generated config by replacing source-managed plaintext apiKey values with a non-secret marker, while preserving marker-based runtime auth references and the registry contract for custom providers.