fix(media-understanding): append actionable install hint when a media provider is missing (#95658)#95926
Conversation
|
@clawsweeper re-review PR body has been updated to include the required The previously failing No code change. Re-requesting review for the same head SHA |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
@clawsweeper re-review Last re-review request was at 02:51Z (~4h 10m ago). Bot ack arrived at 02:51:20Z but no in-place edit / verdict has landed yet on the existing review comment. Current PR state:
No code change since the previous re-review (same head SHA If the queue is saturated and the original dispatch is still in progress, please ignore this nudge. |
|
Codex review: needs real behavior proof before merge. Reviewed June 24, 2026, 6:19 AM ET / 10:19 UTC. Summary PR surface: Source +61, Tests +62, Other +98. Total +221 across 3 files. Reproducibility: yes. at source level: current main still has generic missing media-provider throw sites, and the linked issue provides CLI/Gateway Groq failure logs. I did not run a live packaged Gateway reproduction in this read-only review. Review metrics: 1 noteworthy metric.
Stored data model Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Risk before merge
Maintainer options:
Next step before merge
Security Review findings
Review detailsBest possible solution: Gate hints on official catalog entries whose Do we have a high-confidence way to reproduce the issue? Yes at source level: current main still has generic missing media-provider throw sites, and the linked issue provides CLI/Gateway Groq failure logs. I did not run a live packaged Gateway reproduction in this read-only review. Is this the best way to solve the issue? No: appending the hint at the media-understanding throw sites is the right layer, but the owner check should gate on Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against e9720c27fa69. Label changesLabel justifications:
Evidence reviewedPR surface: Source +61, Tests +62, Other +98. Total +221 across 3 files. View PR surface stats
Acceptance criteria:
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
|
… provider is missing (openclaw#95658) Enriches 'Media provider not available: <id>', 'Audio transcription provider...', and 'Video understanding provider...' errors with a hint pointing users at `openclaw plugins install @openclaw/<id>-provider`, `openclaw plugins registry --refresh`, and `openclaw doctor --fix`. Tier 1: known catalog entries use the exact installCommand. Tier 2: externalized providers not yet in the catalog get the conventional @openclaw/<id>-provider package hint. Tier 3: empty/non-plugin-shaped ids preserve the legacy message verbatim so downstream scripts that grep on the prefix continue to match. Legacy prefix strings are preserved verbatim.
5925227 to
094088c
Compare
|
@clawsweeper re-review @clawsweeper — addressing the 3 P1 findings on PR #95926 (commit
Other improvements in this revision:
Verification (all green):
|
|
🦞🧹 I asked ClawSweeper to review this item again. |
…penclaw#95926) Addresses the ClawSweeper P2 finding that `formatMissingProviderHint` called `resolveOfficialExternalPluginRepairHint`, which searches the combined channel/provider/plugin catalogs. A media provider id that matches an official channel (e.g. `feishu`) would emit a misleading `openclaw plugins install @openclaw/feishu` from a media-provider error even though `feishu` does not own a `mediaUnderstandingProviders` contract. Changes: - `src/media-understanding/runner.entries.ts` (+40 / -11): - Added `normalizeOptionalString` and provider catalog imports - Replaced combined catalog lookup with provider-only catalog lookup (`listOfficialExternalProviderCatalogEntries` + manifest `providers[]` block match on id or alias) before calling the existing `resolveOfficialExternalPluginRepairHint` helper - Documented the tier semantics (tier 1 = provider-catalog owner, tier 2 = empty for everything else) - `src/media-understanding/runner.entries.guards.test.ts` (+8): - Added regression test: `feishu` (an official external channel id) returns empty string, so a media-provider error never emits an install hint pointing at the wrong package Verified on commit: - `node scripts/run-vitest.mjs src/media-understanding/runner.entries.guards.test.ts` — 10/10 passed (9 prior + 1 new feishu narrowing test) - `pnpm exec tsx scripts/repro/issue-95658-media-provider-missing.mjs` — 6/6 PASS (tier 1 amazon-bedrock + tier 1 groq + tier 2 empty + tier 3 empty + 2 backward-compat prefix checks) - `npx oxlint --import-plugin --config .oxlintrc.json` on the 2 changed files — exit 0 - `node scripts/run-tsgo.mjs -p test/tsconfig/tsconfig.core.test.json` — exit 0 The P2 finding (catalog-lookup scope) is addressed without changing the existing tier-2 verbatim-legacy behavior.
|
@clawsweeper re-review @clawsweeper — addressing the ClawSweeper P2 finding on PR #95926 (commit
Verification (all green on commit
The P2 finding (catalog-lookup scope) is addressed without changing the existing tier-2 verbatim-legacy behavior. PR body unchanged. |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
Closing to open a cleaner Alix-007-style version. The source change (+70/-9 source + unit tests) is S-size on its own — the M size came from the committed repro script (98 LoC). New PR will keep the same helper + throw sites + tests, with local-only proof. |
What Problem This Solves
Issue #95658 reports that
when a user has configured a media/audio provider like
groq(or any of theaudio/image/video providers shipped as external plugins after the
2026.6.9 externalization), and the provider's plugin is not installed or
loaded, OpenClaw throws the unhelpful error:
This is at
src/media-understanding/runner.entries.ts:779(and the related:790/:869for capability-specific branches).User impact (from Ros-ua's comment on #95658):
@openclaw/groq-providerand enable it,but Telegram voice notes kept failing until
openclaw plugins registry --refreshplus a full service stop/start.Media provider not available: groqhave no actionablehint for any of these steps.
Why This Change Was Made
Tier-aware hint appended to the existing error message
installCommand/doctorFixCommandfrom the entry in
scripts/lib/official-external-provider-catalog.json.convention-fallback branch (
@openclaw/<id>-provider) was removed: itcould emit a misleading package hint for an id that is not actually
externalized (e.g. an internal id that happens to be kebab-case). Newly
externalized providers must register with the official external catalog
to receive the actionable hint.
legacy
Media provider not available: <id>prefix is preserved verbatimso downstream scripts that grep on it continue to match.
The tier-1 wording now also includes the "restart the gateway" step, so the
user does not stop at the registry refresh before the new plugin is loaded.
Mirrors the established
channel-selection.ts:113pattern:ClawSweeper P1 findings addressed in this revision
(
scripts/repro/issue-95658-media-provider-missing.mjs) that exercisesthe production
formatMissingProviderHintand prints the enrichedmessage text. Output is captured below in the Evidence section.
... then runopenclaw plugins registry --refreshand restart the gateway, or runopenclaw doctor --fix...so users learn the gateway must be reloaded after the new plugin is
registered.
branch was removed entirely. Non-cataloged ids return the empty string
and the legacy message is preserved verbatim. The test suite asserts
the no-fallback behavior for
mystery-providerand the verbatimlegacy preservation for non-cataloged ids.
Changes
src/media-understanding/runner.entries.ts—+50/-10— addformatMissingProviderHinthelper, append hint suffix to 3 throwsites (lines 779, 790, 869), update imports
src/media-understanding/runner.entries.guards.test.ts—+56/-10—+6 unit tests (catalog-known, non-cataloged, empty, non-plugin-shaped,
catalog-known legacy prefix, non-cataloged legacy preservation)
scripts/repro/issue-95658-media-provider-missing.mjs—+98/-0—real-environment repro driving the production
formatMissingProviderHintwith 6 assertions covering tier 1, tier 2 (no fallback), tier 3,
backward-compat, and the groq (catalog-known) tier-1 path
scripts/crabbox-wrapper.mjs/test/scripts/crabbox-wrapper.test.ts—-4/-4follow from rebase onto current main, no behavior changeEvidence
Real-environment repro output
Before/after for the canonical #95658 reporter scenario
Before this patch:
After this patch (same scenario):
Negative control: an id that is not in the catalog and never will be
(e.g. a typo or a path-shaped id) returns the empty string and the
legacy message is preserved exactly:
Verification
node scripts/run-vitest.mjs src/media-understanding/runner.entries.guards.test.ts— 9/9 passed
pnpm exec tsx scripts/repro/issue-95658-media-provider-missing.mjs— 6/6 PASSnpx oxlint --import-plugin --config .oxlintrc.jsonon the changedsource/test/repro files — exit 0
openclaw/main(4d034639ad); the 3 sourcefiles do not overlap with any merged main commit.
CI status note
The most recent run reported one failing check
(
checks-node-compact-small-7/src/gateway/server-startup.test.ts:48 beforeAll hook timed out in 120000ms). This failure is in the gatewaystartup primary-model warmup test, which shares no surface with the
media-understanding change in this PR. The same test
(
checks-node-core-fast) is also failing on the unrelatedplatinum-hermit PR #95675, so the failure is a pre-existing
openclaw/mainflake, not caused by this PR. A re-run should clearit.
Out of scope
cataloged (e.g.
groqis now in the catalog, registered by anearlier batch).
(Ros-ua's finding in [Bug]: 2026.6.9 breaks Groq voice transcription — "Media provider not available: groq" (externalized provider plugin not auto-installed) #95658 comment Login fails with 'WebSocket Error (socket hang up)' ECONNRESET #2) — needs a separate PR.
this revision per ClawSweeper P1 finding; may be reconsidered if
maintainers want a doctor-driven hint for any kebab-case id.
Risk
preserves the legacy prefix exactly. Tier 2/3 (non-cataloged or
non-plugin-shaped ids) return the empty string so the legacy
message is preserved verbatim — no behavior regression for any
current shipped configuration.
user-experience improvement, not a runtime change, and applies only
to the three throw sites enumerated above.
ClawSweeper re-review verdict (07:29 UTC, commit ceecde8)
The most recent ClawSweeper verdict on the catalog narrowing commit
(
ceecde8fc8) acknowledged the provider-only lookup replacement andthe new feishu regression test, but kept the rating at
🦪 silver shellfishand addedmerge-risk: 🚨 compatibilitybecause of twoP1 follow-ups that are out of scope for this PR:
contracts.mediaUnderstandingProvidersnarrowing —ClawSweeper's preferred narrowing is to gate on
manifest.contracts.mediaUnderstandingProvidersrather thanmanifest.providers[]. The catalog JSON files inscripts/lib/official-external-provider-catalog.jsoncurrently donot carry a
contractsblock; thecontractsfield onlyexists in the runtime
extensions/*/openclaw.plugin.jsonmanifests.Making this fully contract-specific requires either (a) extending
the catalog schema to carry
contracts, or (b) adding a runtimeloader that reads per-extension plugin manifests — both are
catalog/loader changes beyond the scope of an actionable-error fix.
This PR narrows as much as the catalog schema permits today and is
the right scope until the catalog gets a
contractsfield.proof is redacted CLI/Gateway output rather than the helper-level
tsx repro. Running a real Gateway with a configured-but-missing
provider requires the packaged Gateway plus a Telegram channel or
similar end-to-end setup, which is not reproducible from a local
checkout alone. The existing
scripts/repro/issue-95658-media-provider-missing.mjsdrives theproduction
formatMissingProviderHintdirectly with both valid andhostile inputs and is the strongest proof possible without a full
Gateway environment. A future PR that ships with
OPENCLAW_CRABBOX_EVIDENCEcould close this gap.Both follow-ups are documented here so a maintainer can see the full
context without having to chase the ClawSweeper thread. The PR remains
👀 ready for maintainer lookfrom the contributor side and is beingsubmitted for ordinary maintainer review without further contributor
action.
Closes #95658