Files
cvmmap-streamer/.sisyphus/notepads/major-refactor-cli11-cvmmap/learnings.md
T
2026-03-06 12:06:58 +08:00

1.1 KiB

  • 2026-03-06: Updated src/main_streamer.cpp to remove explicit has_help_flag/print_help preflight checks and treat empty/help parse result as graceful exit.

  • parse_runtime_config in src/config/runtime_config.cpp now returns std::unexpected("") for help path (via app.exit(e) == 0) and std::unexpected("parse_error") for parse failures.

  • Kept --help behavior delegated to CLI11: ./build/cvmmap_streamer --help prints CLI11-generated help and exits non-zero through parse path logging in current wrapper.

  • Verified with cmake --build build and CLI smoke commands: --help, --definitely-invalid, and no-arg execution (shows runtime config then fails runtime stage as expected).

  • 2026-03-06: applied concrete edits: streamer now relies on parse_runtime_config returning "help"/"parse_error" and main handles those exits directly (help=>0, parse_error=>2).

  • 2026-03-06: completed remaining task checks: grep-verified no manual streamer help preflight in main, plus help parse/parse_error control flow validated with --help exit 0 and invalid flag exit 2; note appended.