Files
clydeRbuegelandClaude Opus 5 88f416e6a5 fix: add __main__ guards to eth2-quickstart, mubu, siyuan and zotero CLIs (#440)
These four CLI modules define their entry point but never invoke it under an
`if __name__ == "__main__":` guard, so `python -m cli_anything.<pkg>.<pkg>_cli`
exits 0 without producing any output. 63 of the 68 CLI modules in the repo
already carry the guard; this brings the remaining ones in line.

Each guard calls the same callable the console script points at, so behaviour
matches an installed run:

- eth2-quickstart -> `main()`
- mubu            -> `raise SystemExit(entrypoint())`
- siyuan          -> `cli()`
- zotero          -> `raise SystemExit(entrypoint())`

`entrypoint()` returns an exit code in mubu and zotero, which `SystemExit`
propagates the same way setuptools' console-script wrapper does.

Refs #436


Claude-Session: https://claude.ai/code/session_01ChPxA9ksnNqr83nLbfMhwu

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-21 15:24:36 +08:00
..
2026-03-18 12:18:31 +08:00

Agent Harness

This directory is now the stricter CLI-Anything-style harness root for Mubu.

Recommended install flow:

cd <repo-root>
python3 -m venv .venv
.venv/bin/python -m pip install -e ./agent-harness

Root install now also targets the same canonical source tree:

cd <repo-root>
.venv/bin/python -m pip install -e .

What this gives you:

  • agent-harness/ works as the editable install root
  • the canonical implementation now lives inside this directory
  • the same cli-anything-mubu console script is exposed
  • the main CLI is Click-based with grouped command domains
  • no-argument daily helpers only work when MUBU_DAILY_FOLDER is configured
  • skill_generator.py can regenerate the packaged skills/SKILL.md

Canonical implementation now lives under:

  • agent-harness/mubu_probe.py
  • agent-harness/cli_anything/mubu

Compatibility shims remain at the project root for local python -m ... and python3 mubu_probe.py workflows:

  • mubu_probe.py
  • cli_anything/mubu

Current supporting references:

  • agent-harness/MUBU.md
  • README.md
  • tests/TEST.md

Current state:

  • packaged and installable from the harness root
  • canonical package source is now under agent-harness/cli_anything/mubu/...
  • root-level wrappers preserve backward compatibility during development
  • grouped discover / inspect / mutate / session commands now exist
  • daily-note helpers require an explicit folder reference unless MUBU_DAILY_FOLDER is set
  • the packaged SKILL.md is now generated from the canonical harness