Skip to content

Shared-list path fix, CLI error-code coverage, doctor + --version #125

Description

@a6b8

Context

A declared sharedLists ref (e.g. evmChains) could arrive empty (content:[]) with status:true — a silent failure. Root cause: callTool/serve rebuilt the schema file path via join(#schemasDir(), file) against the obsolete ~/.flowmcp/schemas staging dir (a Memo-099 migration rest), so _lists/ was never found and shared-list resolution silently returned {}.

Changes

  • Shared-list fix: one source of truth #resolveSchemaFilePath for the schema file path; callTool (param + handler path), serve and the resource-query path all use it. A declared-but-unresolvable shared list now fails loud with a code (LST-001/HND-001) instead of a silent empty list.
  • Error-code coverage: CliError class + a code field on the error helper + #emitCoded (silent on benign ENOENT/ENOTDIR). Every caught failure now carries a PREFIX-NNN code.
  • flowmcp doctor: structural health check over schemaFolders[] (lists / modules / refs / config), reported by code, exit 1 on any ERROR.
  • flowmcp --version / flowmcp version: CLI version stamp.

Verification

922 tests green (860 unit + 62 integration). get_available_chains_etherscan returns the full chain list again. doctor surfaces real pre-existing schema/dependency issues by code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions