Repository navigation
Conversation
## Summary This fixes the items in #1917 that have a clear fix and change no gate behavior. The items that would change what the gate accepts or runs (2, 3, 4, 5, 9) moved to #1936, along with item 14's caller-level cases. Item 1 was settled earlier in #1919. - **Item 10:** the byte-order-mark error reuses the text `shape()` already parsed. It used to read `pyproject.toml` a second time, so a file deleted in between raised an uncaught `FileNotFoundError`. - **Items 12 and 15:** `spec/validate.py` keeps a mixed `types` list's string elements. `["pythn", 3]` now reports the unknown type and no longer draws a false profile error. An explicit `"types": null` on a cataloged entry gets the "add types or mark it backlog" remedy again. - **Item 13:** `scripts/carry.py` reads `types` through a guarded `entry_types()`. It does not use the audit's helper, because a tree carry deliberately never loads the audit. - **Item 15:** the `declared_types()` docstring now says it returns an empty list, and the selftest checks the helper directly. - **Item 6:** AUDIT.md's classification line and the python type's `profileNote` exclude the carried `hub-fetch-run.py`. The `detect` list itself stays `["*.py"]`: nothing reads it in code, and it has no way to write an exclusion. - **Item 7:** WORKFLOW.md D1.2 states that the undeclared root's test leg runs only where `tests/` sits beside a `uv.lock` or `requirements*.txt`. - **Item 8:** the lint-only profile now owes tests unconditionally. Its definition and bounds in `python.profile.detect` and `profileNote` exclude a `requirements*.txt`. - **Item 11:** the Codecov mechanism note ties `CODECOV_TOKEN` to a repo carrying tests for that language. ## Verification - The full unittest suite (1756 tests), mypy, ruff check and format, `spec/validate.py`, and `spec/audit.py --selftest` all pass. - The prose gate (`--diff origin/develop`), the eol checks, `build_dist.py --check`, and `docker_lint.py` are clean. - Each new test fails against the pre-fix code: I reverted each fix and ran the test. - The local strict review ran two rounds. Round 1 raised three findings: item 8's definition was fixed, item 14 moved to #1936, and the `detect` list was declined. Round 2 raised none. Refs #1917. The closing keyword goes on the promotion PR. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Repository: ptr727/ProjectTemplate/.coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1939 +/- ##
==========================================
+ Coverage 55.40% 55.41% +0.01%
==========================================
Files 16 16
Lines 7196 7209 +13
==========================================
+ Hits 3987 3995 +8
- Misses 3209 3214 +5
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
The changes are narrowly scoped, add direct regression tests, and align prose with existing behavior without introducing risky behavioral shifts.
Review effort: Lite
Findings: None
What changed in this PR
This PR promotes develop to main by landing a set of non-behavior-changing fixes and clarifications around the Python directory gate, plus targeted tests to lock in the corrected edge-case handling.
Changes:
- Prevent a TOML byte-order-mark error path from re-reading
pyproject.toml, and add a regression test to enforce single-read behavior. - Treat malformed
typesvalues more robustly by preserving string elements of mixed lists, and add tests and selftests to validate the intended handling. - Align workflow and type-contract documentation (including Codecov and Python profile notes) with the validator’s shipped behavior.
| File | Description |
|---|---|
| WORKFLOW.md | Documents the undeclared-root test-leg preconditions to match validator behavior. |
| tests/test_spec_validate.py | Adds coverage for mixed types lists and explicit types: null remediation messaging. |
| tests/test_python_directories.py | Adds a regression test ensuring the BOM error path does not read the file twice. |
| tests/test_carry.py | Adds coverage that only string elements of types lists become selectors. |
| spec/validate.py | Preserves string elements from mixed types lists while still emitting a shape error. |
| spec/secrets.json | Clarifies that CODECOV_TOKEN is required when tests for that language exist. |
| spec/project-types.json | Updates Python profile/prose assertions to reflect detection and requirements behavior. |
| spec/audit.py | Updates declared_types() docstring and expands selftest cases for malformed types. |
| scripts/carry.py | Adds entry_types() helper and uses it to avoid malformed types causing selector/print issues. |
| AUDIT.md | Excludes the carried hub-fetch-run.py helper from Python-type detection prose. |
| .github/skills/workflow-ci-contract/references/d-guarantees.md | Generated copy of the D1.2 documentation update. |
| .github/skills/python-codestyle/references/profiles.md | Generated copy of the lint-only profile prose update. |
| .github/actions/python-directories/python_directories.py | Reuses parsed TOML text for BOM detection instead of re-reading. |
| .claude-plugin/fleet-skills/skills/workflow-ci-contract/references/d-guarantees.md | Generated plugin copy of the D1.2 documentation update. |
| .claude-plugin/fleet-skills/skills/python-codestyle/references/profiles.md | Generated plugin copy of the lint-only profile prose update. |
| .claude-plugin/fleet-skills/.source-digests/workflow-ci-contract | Updates plugin source digest for workflow-ci-contract. |
| .claude-plugin/fleet-skills/.source-digests/python-codestyle | Updates plugin source digest for python-codestyle. |
| .agents/skills/workflow-ci-contract/references/d-guarantees.md | Source skill content update for D1.2 documentation. |
| .agents/skills/python-codestyle/references/profiles.md | Source skill content update for lint-only profile prose. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Summary
This promotes develop to main.
typeslist inspec/validate.pyandscripts/carry.py, and brings the detection, D1.2, lint-only profile, and Codecov prose in line with shipped behavior. The items that would change gate behavior moved to Decide the Python Directory Gate's Behavior-Changing Edge Cases #1936.Closes #1917
🤖 Generated with Claude Code