mirror of
https://github.com/openclaw/openclaw.git
synced 2026-07-16 22:11:34 +00:00
* refactor(config): retire flat streaming keys from the last six channel schemas
signal, irc, nextcloud-talk, whatsapp, googlechat, and mattermost now accept
only the nested streaming.{chunkMode,block.enabled,block.coalesce} shape
(mattermost also drops scalar/boolean streaming); flat spellings migrate via
each channel's defineChannelAliasMigration doctor contract with root seeding
for their wholesale-replace account merges.
* feat(channels): warn once per key when the deprecated flat streaming fallback is used
Bundled schemas now reject the flat delivery keys, so the streaming.ts
fallback only serves external SDK plugin configs; emit a once-per-process
per-key subsystem warning and pin the removal plan to the next release train.
* chore(config): regenerate bundled channel config metadata for nested-only streaming
* docs: describe nested-only channel streaming config and the SDK flat-key deprecation window
* fix(whatsapp): seed migrated named-account streaming from the accounts.default layer
WhatsApp resolution layers accounts.default shared config between root and
named accounts, so doctor-materialized account streaming objects now inherit
default-account settings over root ones; mattermost schema test moves to the
nested-only shape with explicit rejection coverage; scope flat-key deprecation
notes to the pending Matrix/Feishu migrations.
* fix(whatsapp): resolve the default account case-insensitively when seeding migrated streaming
* chore(plugin-sdk): repin API baseline for nested-only channel streaming types
30 lines
1.2 KiB
TypeScript
30 lines
1.2 KiB
TypeScript
// Irc API module exposes the plugin doctor contract.
|
|
import type {
|
|
ChannelDoctorConfigMutation,
|
|
ChannelDoctorLegacyConfigRule,
|
|
} from "openclaw/plugin-sdk/channel-contract";
|
|
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts";
|
|
import { defineChannelAliasMigration } from "openclaw/plugin-sdk/runtime-doctor";
|
|
|
|
// IRC's nested streaming schema is delivery-only ({chunkMode, block}); it has
|
|
// no preview mode, so only the delivery flat aliases are legal legacy input.
|
|
// Account merge replaces the root streaming object wholesale
|
|
// (resolveMergedAccountConfig without a streaming deep-merge), so migration
|
|
// seeds materialized account objects with the inherited root settings.
|
|
const streamingAliasMigration = defineChannelAliasMigration({
|
|
channelId: "irc",
|
|
streaming: { defaultMode: "partial", deliveryOnly: true },
|
|
accountStreamingReplacesRoot: true,
|
|
});
|
|
|
|
export const legacyConfigRules: ChannelDoctorLegacyConfigRule[] =
|
|
streamingAliasMigration.legacyConfigRules;
|
|
|
|
export function normalizeCompatibilityConfig({
|
|
cfg,
|
|
}: {
|
|
cfg: OpenClawConfig;
|
|
}): ChannelDoctorConfigMutation {
|
|
return streamingAliasMigration.normalizeChannelConfig({ cfg });
|
|
}
|