CI shard (test 1) deterministically failed importing the dingtalk plugin:
alibabacloud_dingtalk transitively imports cryptography and raises
AttributeError ('cryptography.utils' has no attribute 'DeprecatedIn46') when
CI's cryptography is older than the SDK expects. The adapter guarded that SDK
import with 'except ImportError', which does NOT catch AttributeError, so the
whole adapter (and thus plugin discovery via __init__'s 'from .adapter import
register') crashed instead of degrading. Broadened the alibabacloud_dingtalk
guard, the dingtalk_stream guard, and the check_dingtalk_requirements lazy
re-import to 'except Exception' so a broken optional SDK dependency chain
degrades gracefully (CARD_SDK_AVAILABLE/DINGTALK_STREAM_AVAILABLE=False), same
as a missing dep. This was invisible before migration because the inline
adapter was only imported when dingtalk was activated, not at plugin-discovery
time.
CI (test shard 6) caught tests/tools/test_send_message_missing_platforms.py
importing the removed _send_dingtalk/_send_matrix helpers. Added thin
pre-migration-shaped shims around the plugins' _standalone_send (same pattern
mattermost/HA used in this file). Also restored access_token redaction in the
dingtalk plugin's _standalone_send error path (the legacy _send_dingtalk
returned via _error() which redacts URL secrets; the bare plugin return leaked
the webhook access_token in exception text) by reusing send_message_tool._error
via lazy import.
- Sweep test imports gateway.platforms.{telegram,feishu,matrix,dingtalk,whatsapp}
(+ telegram_network / feishu satellites) -> plugins.platforms.<x>.adapter
across ~68 test files; both 'from X import' and 'from gateway.platforms import X'
forms.
- _is_platform_connected now forces discover_plugins() before the registry
lookup so get_connected_platforms() works on directly-constructed GatewayConfig
(fixes dingtalk-recognised tests after its checker moved to the plugin).
- telegram _apply_yaml_config no longer re-emits generic shared-config keys
(reply_prefix etc.) that _merge_platform_map already merges with top-level
precedence, while still passing through telegram-specific extras (base_url).
- prompt_choice lives in hermes_cli.setup, not cli_output — fixed the import in
feishu/dingtalk interactive_setup and the test patch target.
- test_setup_feishu rewritten to drive interactive_setup via the plugin.