Skip to content

fix: downgrade bundled plugin uninstall from ERROR to WARNING#945

Open
livepeer-tessa wants to merge 1 commit intomainfrom
fix/bundled-plugin-uninstall-log-level
Open

fix: downgrade bundled plugin uninstall from ERROR to WARNING#945
livepeer-tessa wants to merge 1 commit intomainfrom
fix/bundled-plugin-uninstall-log-level

Conversation

@livepeer-tessa
Copy link
Copy Markdown
Contributor

Summary

Fixes #837 — ERROR-level log noise on every prod fal.ai job from scope-ltx-2 bundled plugin cleanup attempts.

Root Cause

The uninstall_plugin endpoint was catching all PluginInstallError exceptions (including bundled-plugin rejection) and logging them as ERROR. Attempting to uninstall a bundled plugin is an expected, handled condition — the fal.ai cleanup loop always tries to uninstall all plugins at job end, including bundled ones. It's not a server error.

Changes

  • manager.py: Add PluginBundledError(PluginInstallError) subclass so callers can distinguish bundled-rejection from genuine install failures. Raise it instead of PluginInstallError in _uninstall_plugin_sync when a bundled plugin is targeted.
  • __init__.py: Export PluginBundledError.
  • app.py: Catch PluginBundledError before the generic handler in the uninstall endpoint: log at WARNING, return HTTP 400 (client error) instead of 500 (server error).

Before / After

Before After
Log level ERROR WARNING
HTTP status 500 400
Noise in prod 5+ per 12h window 0 (warning-level, not ERROR-forwarded)

Testing

  • All 99 existing plugin manager tests pass (test_plugin_manager.py)
  • PluginBundledError is a subclass of PluginInstallError so existing except PluginInstallError catch sites in other paths still work correctly

Attempting to uninstall a bundled plugin is an expected, handled
condition — not a server-side failure. This was generating ERROR-level
log noise on every prod fal.ai job that triggered the cleanup path
(issue #837).

Changes:
- Add PluginBundledError(PluginInstallError) subclass in manager.py so
  callers can distinguish bundled-rejection from true install failures
- Raise PluginBundledError instead of PluginInstallError in
  _uninstall_plugin_sync when a bundled plugin is targeted
- In app.py uninstall endpoint, catch PluginBundledError before the
  generic PluginInstallError handler: log at WARNING, return HTTP 400
  (client error) instead of 500 (server error)

Fixes: #837
Signed-off-by: Tessa (livepeer-tessa) <tessa@livepeer.org>
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 15, 2026

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 688eaa2b-fd84-446b-bce8-807c226023b3

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/bundled-plugin-uninstall-log-level

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
Copy Markdown
Contributor

🚀 fal.ai Preview Deployment

App ID daydream/scope-pr-945--preview
WebSocket wss://fal.run/daydream/scope-pr-945--preview/ws
Commit ab7e5e3

Livepeer Runner

App ID daydream/scope-livepeer-pr-945--preview
WebSocket wss://fal.run/daydream/scope-livepeer-pr-945--preview/ws
Auth private

Testing Livepeer Mode

SCOPE_CLOUD_MODE=livepeer SCOPE_CLOUD_APP_ID="daydream/scope-livepeer-pr-945--preview/ws" uv run daydream-scope

@livepeer-tessa
Copy link
Copy Markdown
Contributor Author

Pinging @mjh1 and @emranemran — this has been unresolved since April 3rd and is still generating ERROR-level noise across every prod job (~10 occurrences in the last 12h alone). PR #945 is ready: all CI checks green, no conflicts. Would appreciate a review so we can cut the monitoring noise. 🙏

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[fal.ai] Plugin uninstall failed: scope-ltx-2 is bundled and cannot be uninstalled — ERROR-level noise across all jobs

1 participant