Skip to content

refactor(tools): remove unused auth source hints - #201996

Merged
vincentkoc merged 1 commit into
mainfrom
refactor/web-search-auth-source-20261120
Nov 19, 2026
Merged

vincentkoc merged 1 commit into
mainfrom
refactor/web-search-auth-source-20261120

Conversation

@vincentkoc

@vincentkoc vincentkoc commented Nov 19, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

Tool preparation passes an auth-store-source Boolean through several private callers even though the credential helper never reads it. Four callers still perform asynchronous source probes just to populate that unused hint. Web-search also expresses its live lazy-preparation notification as a Boolean-returning callback whose return value is ignored.

User Impact

No intended change to tool availability, credential selection, or public SDK inputs. Prepared, published, and authoritative empty auth stores remain the credential owners. Config credentials still short-circuit before provider-auth lookup, followed by environment and fallback credentials.

Why This Approach

Remove the unused private hint and its four producer probes. Keep web-search's live notification explicit as a void callback at the same provider-auth lookup point, only when no auth store is supplied. Preserve the lazy preparation/retry path, error order, abort and authority checks, genuine source-check APIs, and real false-source auth test. The complete caller cutover removes 79 lines across 12 production files and two existing test inputs; no dependency, export, or public signature change.

Evidence

  • Frozen base: cd2ae19272a3ee7be456385fa7efc56d6e2109a6; signed candidate: 361dd3fd93ddb4c8d06391ad53c4f283cd0220e2.
  • Fresh independent complete-diff/caller review and committed-range local review found no correctness or security issue. Normal signed commit hooks and whitespace checks passed.
  • Native focused proof passed all 202 cases in 13 files, including web-search runtime/configuration, tool assembly, private SDK options, real false-source image auth, effective inventory, cron/skill/worker preparation, and prompt-prefix stability. Every selected case and assertion remains intact.
  • Whole native test command: 174.76 s wall, 168.06 s user CPU, 90.78 s system CPU, 4,641,374,208 B maximum RSS. These include native guards, setup, and teardown; they are not individual test timings or a comparative benchmark.
  • Normal isolated frozen APP install: 7.4 s, 1,482 package entries reused and zero package-manager downloads. Its ordinary Matrix 0.6.6 hook separately downloaded the public platform binary. The installed dependency document, 252 frozen inputs, runtime/platform, and 4,506 contained dependency/workspace links qualified. No shared or authored-checkout dependency layout was changed.
  • Scoped checks all passed: core production types (8.505 s), agents-root test types (6.643 s), plugin-sdk test types (6.242 s), 14-file lint (7.650 s), and format (0.081 s). All owned commands joined. Existing bundler module-directive and Plugin SDK deprecation warnings were retained.
  • Public SDK API comparison is not applicable: only private hints and internal notification plumbing changed; public agentDir/authStore inputs and exports are unchanged. No performance savings claim.
  • Native review artifact validation and preparation passed without changing the head. Exact-head ready-event CI 44592841610 and required security gates, including final Security Review 44594964983, succeeded. Squash-merged on 2026-11-19 at 19:12:21 UTC as 6d89083ac16992fc8ba67d99b818ef3cbb138dad; native closeout is COMPLETE. The normal merge verifier retained its mainline-infrastructure drift warning and proceeded under existing policy. The focused test/setup results are not a standalone full-build or performance proof.

@vincentkoc vincentkoc self-assigned this Nov 19, 2026
@clawsweeper

clawsweeper Bot commented Nov 19, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

@openclaw-barnacle openclaw-barnacle Bot added gateway Gateway runtime agents Agent runtime and tooling size: S labels Nov 19, 2026
@vincentkoc
vincentkoc marked this pull request as ready for review November 19, 2026 18:55
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Security sensitive changes

This maintainer PR changes sensitive security components.

No secops approval is required. This comment is informational because the PR author has Maintain or Admin access.

  • Current SHA: 361dd3fd93ddb4c8d06391ad53c4f283cd0220e2
  • Maintainer: @vincentkoc
  • Repository role: admin

These security sensitive changes were made:

  • src/gateway/worker-environments/worker-tool-authority.ts: Controls Gateway authentication, pairing, or caller permissions. Check identity validation, scope checks, and revocation.

Carefully review these changes before merging.

@vincentkoc
vincentkoc merged commit 6d89083 into main Nov 19, 2026
237 checks passed
@vincentkoc
vincentkoc deleted the refactor/web-search-auth-source-20261120 branch November 19, 2026 19:12
@vincentkoc

Copy link
Copy Markdown
Member Author

Merged via squash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling gateway Gateway runtime security-sensitive-changed size: S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant