惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Hugging Face - Blog
Hugging Face - Blog
量子位
H
Help Net Security
Microsoft Azure Blog
Microsoft Azure Blog
MongoDB | Blog
MongoDB | Blog
小众软件
小众软件
爱范儿
爱范儿
博客园 - 【当耐特】
Vercel News
Vercel News
S
SegmentFault 最新的问题
M
MIT News - Artificial intelligence
F
Fortinet All Blogs
Apple Machine Learning Research
Apple Machine Learning Research
GbyAI
GbyAI
博客园 - 叶小钗
博客园_首页
V
Visual Studio Blog
宝玉的分享
宝玉的分享
B
Blog
MyScale Blog
MyScale Blog
C
Check Point Blog
博客园 - 三生石上(FineUI控件)
L
LangChain Blog
V
V2EX

Recent Commits to openclaw:main

test: merge chat side-result checks · openclaw/openclaw@ddd2c2a test: merge cron history checks · openclaw/openclaw@f7eb746 test: merge responsive navigation shell checks · openclaw/openclaw@c2e4b47 docs(changelog): add codex oauth fixes · openclaw/openclaw@628e6cd test: merge navigation routing cases · openclaw/openclaw@5d8cecb Tests: mock channel registry bundled fallback · openclaw/openclaw@2b08233 Secrets: avoid broad web search discovery for single plugin config · openclaw/openclaw@a464f59 test: merge config view browser checks · openclaw/openclaw@20cf511 fix(status): align oauth health with runtime · openclaw/openclaw@eed7116 feat: add macOS screen snapshots for monitor preview (#67954) thanks … · openclaw/openclaw@f377db1 fix: report shared auth scopes in hello-ok (#67810) thanks @BunsDev · openclaw/openclaw@0b6c39b Auto-reply: avoid eager bundled route fallback · openclaw/openclaw@3ea1bf4 Tests: narrow session binding contract setup · openclaw/openclaw@54e4e16 fix(macOS): enable undo/redo in webchat composer text input (#34962) · openclaw/openclaw@00951dc Tests: speed up channel setup promotion · openclaw/openclaw@82b529a Docs: refresh agent instructions · openclaw/openclaw@5775fe2 fix(auth): serialize OAuth refresh across agents to fix #26322 (#67876) · openclaw/openclaw@8e79080 test: allow ollama public surface boundary test · openclaw/openclaw@7d4f1a6 Docs: add test performance guardrails · openclaw/openclaw@89706d3 Tests: restore context-engine usage proof · openclaw/openclaw@e4c4f95 Tests: slim context engine runtime coverage · openclaw/openclaw@74c198f ci: retry failed custom checkouts · openclaw/openclaw@0ee5baf test: trim duplicate provider auth onboarding cases · openclaw/openclaw@1ffc02e matrix: fix sessions_spawn --thread subagent session spawning (#67643) · openclaw/openclaw@1ce2596 test: reduce auth choice fixture churn · openclaw/openclaw@857b9cd test: mock health status config boundaries · openclaw/openclaw@9d5ab4a test: mock onboard config io boundary · openclaw/openclaw@299694d test: mock legacy state plugin boundaries · openclaw/openclaw@2713089 test: mock channel install boundaries · openclaw/openclaw@b945248 test: mock doctor preview channel boundaries · openclaw/openclaw@b1a3ad4
fix(telegram): migrate account topic cache sidecars · ope...
obviyus · 2026-05-24 · via Recent Commits to openclaw:main

@@ -112,36 +112,64 @@ function detectTelegramBotInfoCacheLegacyStateMigration(params: {

112112

});

113113

}

114114115+

function topicNameCacheImportSource(params: {

116+

sourceStorePath: string;

117+

targetStorePath?: string;

118+

}): { sourcePath: string; namespace: string } {

119+

const targetStorePath = params.targetStorePath ?? params.sourceStorePath;

120+

const scope = resolveTopicNameCacheScope(targetStorePath);

121+

return {

122+

sourcePath: resolveTopicNameCachePath(params.sourceStorePath),

123+

namespace: resolveTopicNameCacheNamespace(scope),

124+

};

125+

}

126+115127

function detectTelegramTopicNameCacheLegacyStateMigration(params: {

116128

cfg: OpenClawConfig;

117129

env: NodeJS.ProcessEnv;

118130

stateDir?: string;

119131

}): ChannelLegacyStateMigrationPlan[] {

120-

const storePath = resolveStorePath(params.cfg.session?.store, { env: params.env });

121-

const runtimePersistedPath = resolveTopicNameCachePath(storePath);

132+

const accountSources = listTelegramAccountIds(params.cfg).map((accountId) => {

133+

const storePath = resolveStorePath(params.cfg.session?.store, {

134+

env: params.env,

135+

agentId: accountId,

136+

});

137+

return topicNameCacheImportSource({ sourceStorePath: storePath });

138+

});

139+

const defaultStorePath = resolveStorePath(params.cfg.session?.store, { env: params.env });

140+

const defaultAccountStorePath = resolveStorePath(params.cfg.session?.store, {

141+

env: params.env,

142+

agentId: resolveDefaultTelegramAccountId(params.cfg),

143+

});

122144

const legacyStorePath = resolveLegacySessionStorePath(params);

123-

const legacyPersistedPath = resolveTopicNameCachePath(legacyStorePath);

124-

const scope = resolveTopicNameCacheScope(storePath);

125-

const namespace = resolveTopicNameCacheNamespace(scope);

126-

const sourcePaths = Array.from(new Set([runtimePersistedPath, legacyPersistedPath]));

127-

return sourcePaths.flatMap((persistedPath) => {

128-

if (!fileExists(persistedPath)) {

145+

const sourcesByKey = new Map(

146+

[

147+

...accountSources,

148+

topicNameCacheImportSource({ sourceStorePath: defaultStorePath }),

149+

topicNameCacheImportSource({

150+

sourceStorePath: legacyStorePath,

151+

targetStorePath: defaultAccountStorePath,

152+

}),

153+

].map((source) => [`${source.sourcePath}\0${source.namespace}`, source] as const),

154+

);

155+

return [...sourcesByKey.values()].flatMap((source) => {

156+

if (!fileExists(source.sourcePath)) {

129157

return [];

130158

}

131159

return {

132160

kind: "plugin-state-import",

133161

label: "Telegram forum topic-name cache",

134-

sourcePath: persistedPath,

135-

targetPath: `plugin state:${namespace}`,

162+

sourcePath: source.sourcePath,

163+

targetPath: `plugin state:${source.namespace}`,

136164

pluginId: "telegram",

137-

namespace,

165+

namespace: source.namespace,

138166

maxEntries: TELEGRAM_TOPIC_NAME_CACHE_MAX_ENTRIES,

139167

scopeKey: "",

140168

cleanupSource: "rename",

141-

preview: `- Telegram forum topic-name cache: ${persistedPath} → plugin state (${namespace})`,

169+

preview: `- Telegram forum topic-name cache: ${source.sourcePath} → plugin state (${source.namespace})`,

142170

readEntries: () => {

143171

return listTelegramLegacyTopicNameCacheEntries({

144-

persistedPath,

172+

persistedPath: source.sourcePath,

145173

maxEntries: TELEGRAM_TOPIC_NAME_CACHE_MAX_ENTRIES,

146174

});

147175

},