Skip to content

docs(cli): complete CLI exit codes documentation in docs/cli.md (#107) - #277

Merged
himanshu231204 merged 1 commit into
OpenAgentHQ:mainfrom
PrinceThummar011:docs/107-cli-exit-codes
Aug 8, 2026
Merged

docs(cli): complete CLI exit codes documentation in docs/cli.md (#107)#277
himanshu231204 merged 1 commit into
OpenAgentHQ:mainfrom
PrinceThummar011:docs/107-cli-exit-codes

Conversation

@PrinceThummar011

Copy link
Copy Markdown
Contributor

Summary

Completes the CLI exit codes documentation in docs/cli.md per issue #107, ensuring
scripts and CI/CD pipelines have accurate, complete reference for command exit statuses.

Problem

While docs/cli.md already contained a partial exit codes table (0–5), it was missing:

  • Exit code 6 (CorpusError), which is actively used in the codebase
  • A short introductory line explaining the purpose of the table

Changes

  • Added exit code 6 (Corpus error) to the exit codes table, sourced directly from
    the _ERROR_CODES mapping in openagent_eval/cli/main.py
  • Added a contextual intro line above the table: "The CLI returns the following exit
    codes so scripts and CI/CD pipelines can check command results."

Verification

  • ✅ Cross-referenced documented codes against _ERROR_CODES in openagent_eval/cli/main.py
  • ✅ Manually confirmed exit codes at runtime:
    • --version0
    • invalid command → 2
    • invalid config path → 2
  • uv run mkdocs build — docs build passes cleanly
  • uv run pytest tests/unit/test_cli/ — 107/107 tests passing

Notes

A prior claim on this issue reported the exit codes table already existed. This PR
verifies that claim against the source code and closes the remaining gap (missing
code 6 and context line) rather than duplicating existing work.

Closes #107

Copilot AI lite review requested due to automatic review settings August 6, 2026 12:23

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the CLI reference documentation to fully describe the exit codes that oaeval can return, aligning the docs with the CLI’s actual error-to-exit-code mapping so scripts and CI/CD pipelines can reliably interpret outcomes.

Changes:

  • Adds a short introductory sentence explaining the purpose of the exit code table.
  • Updates the exit code table to include code 6 for “Corpus error”.
  • Refines the description for exit code 1 to “General or runtime error”.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@himanshu231204
himanshu231204 merged commit d76c6ce into OpenAgentHQ:main Aug 8, 2026
9 checks passed
@github-actions

github-actions Bot commented Aug 8, 2026

Copy link
Copy Markdown

🎉 Congratulations @PrinceThummar011!

Your pull request has been successfully merged into main. 🚀

Thank you for contributing to OpenAgentHQ and helping improve the project.

We truly appreciate your contribution and hope to see you back with more amazing PRs!

Happy Open Sourcing! ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add CLI exit codes documentation to docs/cli.md

3 participants