[codex] Bootstrap parser-first Python project harness#1
Merged
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5bee112802
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
python-lang-project-harnessas a standalone Python library package with the project distribution name and console script.python_lang_parseras the parser-owned foundation for AST/compile/tokenize/symtable facts, module identity, public surface, symbol roles, source lines, compact parser diagnostics, and parser-owned reasoning-tree facts.__all__contract kind.python_lang_project_harnessas the consumer-facing harness layer for project-wide discovery, rule packs, compact rendering, JSON rendering, CLI, pytest embedding, and advisoryPY-AGENT-*policy.PythonHarnessConfig,[tool.python-lang-project-harness]inpyproject.toml, CLI, and pytest plugin options: selected rule ids can be disabled or promoted to blocking without changing rule catalog severities.src/testsas policy classification roots;--no-testsremains the explicit parser exclusion for tests.PY-MOD-R007for module/package owner shadows and advisoryPY-AGENT-R007for branch packages lacking intent docstrings.render_python_reasoning_tree(report)so repair agents can consume a compact project tree with nodes, branch flags, export names, internal imports, and shadows before editing code.[project].name,[project].requires-python, and[build-system].requires, with compact snapshots.python_lang_project_harness.pytest) and a pytest11 plugin (--python-project-harness), including apytestoptional extra and subprocess coverage for downstream plugin usage.Validation
uv sync --group test --lockeduv run --group test ruff format --check src testsuv run --group test ruff check src testsuv run --group test pytest tests -q(196 passed)uv run python-project-harness .(Files: 98 Parsed: 98)uv buildgit diff --check && git diff --cached --checkast/tokenize/ symbol-shape hardcoding matchesNotes
The remote repository was empty, so I pushed an empty
maininitialization commit first and opened this PR fromcodex/python-harness-bootstrapintomain.