release
Cut and publish a janus-guard release to PyPI. Use when asked to release, tag, or publish a new version of this package.
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Cut and publish a janus-guard release to PyPI. Use when asked to release, tag, or publish a new version of this package.
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
| name | release |
| description | Cut and publish a janus-guard release to PyPI. Use when asked to release, tag, or publish a new version of this package. |
Execute in this order. Do not reorder: gate → versions → CHANGELOG → commit → build → tag → confirm → publish → verify.
uv run pytest — full suite. tests/smoke/ skips unless JANUS_LIVE_SMOKE=1; do NOT require a live smoke run. Instead, read the "Verified runs" table in plans/claude-agent-sdk-hardening.md and report the date and pinned SDK/CLI versions of the last verified run in your release summary.uv run ruff check .uv run mypy janustests/test_import_hygiene.py, which already ran in pytest). Run a Python subprocess that:
sys.meta_path finder whose find_spec raises ImportError for top-level openai, jinja2, and dotenv;import janus, import janus.testing, import janus.adapters.claude_agent_sdk;janus.testing.decide(...) call end to end, e.g.
decide({"read_file": [{"priority": 1, "effect": 0, "conditions": {"path": r"^README"}, "fallback": 0}]}, "read_file", {"path": "README.md"}) and asserts .allowed;janus.generate_policy raises an ImportError whose message mentions the generate extra.
Rationale: core install must stay stdlib + jsonschema + pydantic; this catches an accidental eager import that unit tests on the dev env can miss.[project.optional-dependencies] in pyproject.toml. Every dependency in a named extra that the full stack needs must also appear in all and (where the test suite needs it) dev. Known intentional duplication: generate's openai + jinja2 are deliberately in both all and dev. This has drifted before — check it, don't assume.If anything fails: stop, report, fix or hand back. Never proceed to versioning on a red gate.
## [Unreleased] in CHANGELOG.md. The project follows semver; breaking entries are bolded **BREAKING — ...**. Any breaking entry forces at least a minor bump pre-1.0.pyproject.toml → [project] versionjanus/__init__.py → __version__grep -n 'version' pyproject.toml | head -3 && grep -n '__version__ =' janus/__init__.py## [Unreleased] to ## [X.Y.Z] — YYYY-MM-DD (today's date).## [Unreleased] section above it.git add the three files and commit: Release vX.Y.Z.uv buildtar -tzf dist/*.tar.gz, unzip -l dist/*.whl) for accidents: no .env, no plans/, no stray files. Check what [tool.hatch.build] in pyproject.toml actually includes rather than assuming.git tag vX.Y.Z and push the commit and the tag.~/.pypirc, UV_PUBLISH_TOKEN, trusted publishing via CI) rather than assuming; use uv publish or twine upload dist/* accordingly.pip index versions janus-guard (or the PyPI project page).