mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-11 13:41:53 +00:00
Probe the projects.* RPC surface, block create with a clear update hint, and avoid the raw "unknown method" toast. Includes i18n for en, zh, ja, and zh-hant. Fixes NousResearch/hermes-agent#54999
6 lines
299 B
TypeScript
6 lines
299 B
TypeScript
/** True when a JSON-RPC call failed because the backend predates the method. */
|
|
export function isMissingRpcMethod(error: unknown): boolean {
|
|
const message = error instanceof Error ? error.message : String(error)
|
|
|
|
return /method not found|-32601|unknown method|no such method/i.test(message)
|
|
}
|