Summary
The CI workflow (ci.yml) runs tests against Python 3.11 and 3.12 only, while pyproject.toml declares requires-python = ">=3.11". No linting (Ruff), type checking (mypy/pyright), or formatting (Black) steps are included in CI. The test suite does not cover the opencode_go.py module at all, and there are no integration tests for the actual upstream forwarding paths (ChatGPT passthrough, _chatgpt_passthrough, _post_openai_chat with a real mock upstream).
Evidence
.github/workflows/ci.yml:
steps:
- name: Compile check
run: python -m compileall codex_shim/ -q
- name: Run tests
run: python -m pytest tests/ -q
No ruff check, black --check, or mypy step. No Python 3.13 matrix entry despite the workspace CLAUDE.md targeting 3.13.
tests/ directory listing — no test_opencode_go.py file exists.
pyproject.toml dev dependencies:
[project.optional-dependencies]
dev = [
"pytest>=8",
"pytest-asyncio>=0.23",
]
No ruff, mypy, black, or coverage in dev dependencies.
Why this matters
- Without static analysis in CI, type errors and unreachable code paths (such as the event-loop deadlock documented in a separate issue) go undetected until production failures.
- Without coverage enforcement, critical paths like
_resolve_api_key fallback chain, _maybe_intercept_web_search, and opencode_go.py are untested.
- Without formatting/linting in CI, code quality gates are purely voluntary.
opencode_go.py makes live HTTP calls (urlopen) with no mocking; its error handling paths (network failure, malformed response, HTTP 4xx from the probe endpoints) are completely untested.
Root cause
The project is early-stage and CI was added as a basic smoke-test gate rather than a comprehensive quality pipeline.
Recommended fix
Add the following CI steps:
- name: Lint
run: python -m ruff check codex_shim/ tests/
- name: Format check
run: python -m black --check codex_shim/ tests/
- name: Type check
run: python -m mypy codex_shim/ --ignore-missing-imports
- name: Tests with coverage
run: python -m pytest tests/ -q --cov=codex_shim --cov-fail-under=70
Add ruff, black, mypy, and pytest-cov to dev dependencies in pyproject.toml. Add test_opencode_go.py covering at minimum: successful model discovery, HTTP error handling, and the write_opencode_go_models merge logic.
Acceptance criteria
- CI includes lint, format, and type-check steps that fail the build on violations.
- Code coverage is measured and reported.
opencode_go.py has at least basic test coverage for error paths.
- Python 3.13 is added to the test matrix.
Suggested labels
ci-cd, testing, technical-debt
Priority
P2
Severity
Low — no direct security or reliability impact, but absence of quality gates allows regressions to reach users undetected.
Confidence
Confirmed — ci.yml and pyproject.toml are explicit about what is and is not checked.
Summary
The CI workflow (
ci.yml) runs tests against Python 3.11 and 3.12 only, whilepyproject.tomldeclaresrequires-python = ">=3.11". No linting (Ruff), type checking (mypy/pyright), or formatting (Black) steps are included in CI. The test suite does not cover theopencode_go.pymodule at all, and there are no integration tests for the actual upstream forwarding paths (ChatGPT passthrough,_chatgpt_passthrough,_post_openai_chatwith a real mock upstream).Evidence
.github/workflows/ci.yml:No
ruff check,black --check, ormypystep. No Python 3.13 matrix entry despite the workspace CLAUDE.md targeting 3.13.tests/directory listing — notest_opencode_go.pyfile exists.pyproject.tomldev dependencies:No
ruff,mypy,black, orcoveragein dev dependencies.Why this matters
_resolve_api_keyfallback chain,_maybe_intercept_web_search, andopencode_go.pyare untested.opencode_go.pymakes live HTTP calls (urlopen) with no mocking; its error handling paths (network failure, malformed response, HTTP 4xx from the probe endpoints) are completely untested.Root cause
The project is early-stage and CI was added as a basic smoke-test gate rather than a comprehensive quality pipeline.
Recommended fix
Add the following CI steps:
Add
ruff,black,mypy, andpytest-covto dev dependencies inpyproject.toml. Addtest_opencode_go.pycovering at minimum: successful model discovery, HTTP error handling, and thewrite_opencode_go_modelsmerge logic.Acceptance criteria
opencode_go.pyhas at least basic test coverage for error paths.Suggested labels
ci-cd, testing, technical-debt
Priority
P2
Severity
Low — no direct security or reliability impact, but absence of quality gates allows regressions to reach users undetected.
Confidence
Confirmed —
ci.ymlandpyproject.tomlare explicit about what is and is not checked.