Skip to content

gateway: enabling Feishu from onboard/channels does not install the optional extra and suggests a source-only uv sync command #88

Description

@xiaozuoyou

Summary

When Raven is installed via the official installer / release wheel, enabling the feishu channel from raven onboard or raven channels enable feishu ... only writes config. It does not install the channel-feishu optional dependency (lark-oapi), so raven gateway later disables the channel and logs:

feishu channel disabled: missing dependency (...). Run: uv sync --extra channel-feishu

That remediation is source-checkout-only. End users installed from the one-line installer do not have a local pyproject.toml checkout, so they cannot run uv sync --extra channel-feishu successfully.

Steps to reproduce

  1. Install Raven via the official installer / release wheel path.
    • install.sh remote mode uses uv tool install --force "$wheel_url" at install.sh:175-188.
    • install.ps1 remote mode uses uv tool install --force $wheelUrl at install.ps1:229-232.
  2. Run raven onboard and select the feishu channel, or run raven channels enable feishu --app-id ... --app-secret ....
  3. Start the gateway with raven gateway.
  4. Observe that Feishu is not started and the warning suggests uv sync --extra channel-feishu.

Expected behavior

Selecting / enabling a channel should either:

  • install the required extra automatically before marking the channel usable, or
  • block/guide the user with a command that works for release-wheel installs (not a source-tree-only uv sync command).

At minimum, the remediation shown at gateway startup should match the actual installation mode.

Actual behavior

  • raven onboard / raven channels enable only enables config fields and never installs the channel dependency.
  • ChannelManager catches the deferred ImportError and disables the channel at runtime.
  • The warning points users at uv sync --extra channel-feishu, which requires running inside a Raven source checkout with pyproject.toml.

Root cause analysis

  • pyproject.toml:47-64 declares Feishu support as an optional extra: channel-feishu = ["lark-oapi>=1.5.0,<2.0.0"].
  • The official installers do a base uv tool install in release mode and do not install any channel-* extras:
    • install.sh:175-188
    • install.ps1:229-232
  • Channel onboarding/enabling only writes config and returns success; it never verifies or installs the adapter dependency:
    • raven/cli/onboard_commands.py:1579-1587
    • raven/cli/onboard_commands.py:1776-1789
  • Gateway startup defers adapter imports until runtime; when lark_oapi is missing it logs a warning and disables the channel:
    • raven/channels/manager.py:28-54
  • The warning hardcodes uv sync --extra channel-..., which is appropriate for a source checkout but not for uv tool install users.

Expected fix direction

Any of these would solve the product bug:

  • auto-install the selected channel extra during onboard / channels enable
  • add an installation helper command that works for tool installs and call it from onboarding
  • change the gateway warning so it detects install mode and suggests a valid command for wheel/tool installs

Environment

OS: macOS (user report)
Shell: zsh (user report)
Installation method: official installer / release wheel path
Raven source analyzed: main @ 040fc15

Logs or screenshots

User-observed gateway log:

feishu channel disabled: missing dependency (...). Run: uv sync --extra channel-feishu
Warning: No channels enabled

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions