claude-dev-env 2.16.0 → 2.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agents/agents/AGENTS.md +6 -0
- package/.agents/skills/AGENTS.md +34 -35
- package/.agents/skills/_shared/pr-loop/AGENTS.md +22 -15
- package/.agents/skills/_shared/pr-loop/portable-driver.md +6 -7
- package/.agents/skills/_shared/pr-loop/prompts/AGENTS.md +2 -2
- package/.agents/skills/_shared/pr-loop/scripts/AGENTS.md +1 -1
- package/.agents/skills/_shared/pr-loop/scripts/portable_converge_driver.py +25 -16
- package/.agents/skills/_shared/pr-loop/scripts/skills_pr_loop_constants/portable_driver_constants.py +1 -5
- package/.agents/skills/autoconverge/reference/convergence-gates.md +31 -0
- package/.agents/skills/autoconverge/reference/convergence.md +8 -10
- package/.agents/skills/autoconverge/reference/gotchas.md +1 -1
- package/.agents/skills/autoconverge/reference/stop-conditions.md +1 -1
- package/.agents/skills/autoconverge/workflow/converge.codex-gate.test.mjs +1 -1
- package/.agents/skills/autoconverge/workflow/converge.contract.test.mjs +1 -1
- package/.agents/skills/autoconverge/workflow/converge.mjs +3 -3
- package/.agents/skills/cert-classification-rule/SKILL.md +224 -0
- package/.agents/skills/cert-classification-rule/scripts/resort_cert_folders.py +158 -0
- package/.agents/skills/eli5/SKILL.md +128 -0
- package/.agents/skills/eli5/reference/task-seeds.md +11 -0
- package/.agents/skills/fresh-branch/scripts/test_create_fresh_branch.py +2 -3
- package/.agents/skills/name-by-capability-audit/SKILL.md +67 -0
- package/.agents/skills/name-by-capability-audit/reference/fetch-commands.md +29 -0
- package/.agents/skills/name-by-capability-audit/reference/offense-examples.md +32 -0
- package/.agents/skills/name-by-capability-audit/reference/report-template.md +29 -0
- package/.agents/skills/name-by-capability-audit/reference/rule-checklist.md +38 -0
- package/.agents/skills/name-by-capability-audit/reference/task-seeds.md +9 -0
- package/.agents/skills/orchestrator/SKILL.md +6 -4
- package/.agents/skills/orchestrator-refresh/SKILL.md +9 -5
- package/.agents/skills/pr-cleanup/SKILL.md +99 -0
- package/.agents/skills/prototype/reference/honest-limitations.md +1 -1
- package/.agents/skills/prototype/reference/promotion-tasks.md +1 -1
- package/.agents/skills/prototype/scripts/test_build_sandbox_settings.py +2 -2
- package/.agents/skills/prototype/workflows/promotion.md +2 -2
- package/.agents/skills/review-router/SKILL.md +51 -0
- package/.agents/skills/review-router/reference/route-policy.json +7 -0
- package/.agents/skills/review-router/reference/task-seeds.md +1 -0
- package/.agents/skills/review-router/scripts/conftest.py +4 -0
- package/.agents/skills/review-router/scripts/review_router.py +50 -0
- package/.agents/skills/review-router/scripts/review_router_cli.py +211 -0
- package/.agents/skills/review-router/scripts/review_router_constants/__init__.py +1 -0
- package/.agents/skills/review-router/scripts/review_router_constants/config/__init__.py +0 -0
- package/.agents/skills/review-router/scripts/review_router_constants/config/constants.py +13 -0
- package/.agents/skills/review-router/scripts/test_review_router.py +23 -0
- package/.agents/skills/review-router/scripts/test_review_router_cli.py +47 -0
- package/.agents/skills/review-tier/SKILL.md +56 -0
- package/.agents/skills/review-tier/reference/task-seeds.md +1 -0
- package/.agents/skills/review-tier/reference/tier-policy.json +9 -0
- package/.agents/skills/review-tier/scripts/conftest.py +4 -0
- package/.agents/skills/review-tier/scripts/review_tier.py +332 -0
- package/.agents/skills/review-tier/scripts/review_tier_constants/__init__.py +1 -0
- package/.agents/skills/review-tier/scripts/review_tier_constants/config/__init__.py +0 -0
- package/.agents/skills/review-tier/scripts/review_tier_constants/config/constants.py +29 -0
- package/.agents/skills/review-tier/scripts/test_generation.py +171 -0
- package/.agents/skills/review-tier/scripts/test_review_tier.py +33 -0
- package/.agents/skills/session-log/SKILL.md +1 -1
- package/.agents/skills/shared-extraction-audit/SKILL.md +160 -0
- package/.agents/skills/shared-extraction-audit/reference/examples.md +46 -0
- package/.agents/skills/shared-extraction-audit/reference/offense-taxonomy.md +100 -0
- package/.agents/skills/source-command-logifix/SKILL.md +29 -0
- package/.agents/skills/source-command-sr-loop/SKILL.md +58 -0
- package/.agents/skills/team-advisor/SKILL.md +5 -5
- package/.agents/skills-archived/AGENTS.md +45 -0
- package/.agents/{skills → skills-archived}/anthropic-plan/AGENTS.md +1 -1
- package/.agents/{skills → skills-archived}/bugteam/scripts/reflow_skill_md.py +3 -3
- package/.agents/{skills → skills-archived}/codex-review/test_skill_scaffold.py +1 -1
- package/.agents/{skills → skills-archived}/copilot-finding-triage/SKILL.md +1 -1
- package/.agents/{skills → skills-archived}/pr-converge/SKILL.md +6 -6
- package/.agents/{skills → skills-archived}/pr-converge/pr_converge_skill_constants/AGENTS.md +1 -1
- package/.agents/{skills → skills-archived}/pr-converge/pr_converge_skill_constants/constants.py +1 -1
- package/.agents/{skills → skills-archived}/pr-converge/reference/multi-pr-orchestration.md +1 -1
- package/.agents/{skills → skills-archived}/pr-converge/reference/per-tick.md +3 -3
- package/.agents/{skills → skills-archived}/pr-converge/scripts/reflow_skill_md.py +2 -2
- package/.agents/{skills → skills-archived}/pr-converge/test_portable_pacer_gate.py +6 -2
- package/.agents/{skills → skills-archived}/pr-converge/workflows/schedule-wakeup-loop.md +1 -1
- package/.agents/{skills → skills-archived}/split-pr/reference/proposal-format.md +1 -1
- package/AGENTS.md +34 -58
- package/_shared/AGENTS.md +2 -0
- package/_shared/advisor/AGENTS.md +5 -5
- package/_shared/advisor/advisor-protocol.md +54 -31
- package/_shared/advisor/reference/advisor-block.md +5 -1
- package/_shared/advisor/reference/consult-format.md +1 -1
- package/_shared/advisor/reference/identity.md +28 -0
- package/_shared/advisor/reference/lifecycle.md +8 -1
- package/_shared/advisor/reference/sol-rung.md +14 -9
- package/_shared/advisor/reference/spawn-walk-log.md +6 -5
- package/_shared/advisor/reference/third-party-bind.md +6 -7
- package/_shared/advisor/reference/warm-up.md +9 -2
- package/_shared/advisor/scripts/codex_sol_advisor.py +66 -11
- package/_shared/advisor/scripts/config/advisor_scripts_constants/advisor_route_constants.py +9 -0
- package/_shared/advisor/scripts/config/advisor_scripts_constants/model_tier_run_validator_constants.py +16 -4
- package/_shared/advisor/scripts/config/advisor_scripts_constants/sol_advisor_constants.py +11 -10
- package/_shared/advisor/scripts/model_tier_run_validator.py +50 -23
- package/_shared/advisor/scripts/tests/test_codex_sol_advisor.py +108 -3
- package/_shared/advisor/scripts/tests/test_model_tier_run_validator.py +171 -82
- package/_shared/advisor/scripts/tests/test_tier_model_ids.py +43 -0
- package/_shared/advisor/scripts/tier_model_ids.py +75 -7
- package/_shared/pr-loop/audit-reply-template.md +4 -0
- package/_shared/pr-loop/fix-protocol.md +7 -6
- package/_shared/pr-loop/gh-payloads.md +8 -6
- package/_shared/pr-loop/precatch-rubric.md +6 -5
- package/_shared/pr-loop/scripts/AGENTS.md +15 -0
- package/_shared/pr-loop/scripts/_pr_converge_path_setup.py +38 -0
- package/_shared/pr-loop/scripts/check_bugbot_ci.py +279 -0
- package/_shared/pr-loop/scripts/check_convergence.py +923 -0
- package/_shared/pr-loop/scripts/check_convergence_availability.py +275 -0
- package/_shared/pr-loop/scripts/check_convergence_gates.py +279 -0
- package/_shared/pr-loop/scripts/check_convergence_thread_gates.py +219 -0
- package/_shared/pr-loop/scripts/check_pending_reviews.py +154 -0
- package/_shared/pr-loop/scripts/codex_down_classifier.py +98 -0
- package/_shared/pr-loop/scripts/codex_review_scripts_constants/.claude/CLAUDE.md +1 -0
- package/_shared/pr-loop/scripts/codex_review_scripts_constants/AGENTS.md +18 -0
- package/_shared/pr-loop/scripts/codex_review_scripts_constants/__init__.py +1 -0
- package/_shared/pr-loop/scripts/codex_review_scripts_constants/classifier_constants.py +35 -0
- package/_shared/pr-loop/scripts/codex_review_scripts_constants/codex_usage_probe_constants.py +82 -0
- package/_shared/pr-loop/scripts/codex_review_scripts_constants/findings_constants.py +18 -0
- package/_shared/pr-loop/scripts/codex_review_scripts_constants/run_constants.py +53 -0
- package/_shared/pr-loop/scripts/codex_usage_probe.py +570 -0
- package/_shared/pr-loop/scripts/conftest.py +43 -0
- package/_shared/pr-loop/scripts/fetch_copilot_reviews.py +134 -0
- package/_shared/pr-loop/scripts/fixtures/auth_failure_synthetic.txt +1 -0
- package/_shared/pr-loop/scripts/fixtures/config_load_failure_v0.125.0.txt +1 -0
- package/_shared/pr-loop/scripts/fixtures/freeform_findings_v0.144.3.txt +6 -0
- package/_shared/pr-loop/scripts/fixtures/model_rejection_v0.125.0.jsonl +5 -0
- package/_shared/pr-loop/scripts/fixtures/structured_findings.txt +13 -0
- package/_shared/pr-loop/scripts/fixtures/success_stream_v0.144.3.jsonl +6 -0
- package/_shared/pr-loop/scripts/fixtures/unknown_failure_synthetic.txt +1 -0
- package/_shared/pr-loop/scripts/fixtures/usage_limit_synthetic.txt +1 -0
- package/_shared/pr-loop/scripts/parse_codex_findings.py +207 -0
- package/_shared/pr-loop/scripts/post_fix_reply.py +168 -0
- package/_shared/pr-loop/scripts/pr_converge_scripts_constants/.claude/CLAUDE.md +1 -0
- package/_shared/pr-loop/scripts/pr_converge_scripts_constants/AGENTS.md +18 -0
- package/_shared/pr-loop/scripts/pr_converge_scripts_constants/__init__.py +0 -0
- package/_shared/pr-loop/scripts/pr_converge_scripts_constants/convergence_gate_constants.py +70 -0
- package/_shared/pr-loop/scripts/pr_converge_scripts_constants/pr_converge_constants.py +118 -0
- package/_shared/pr-loop/scripts/pr_converge_scripts_constants/reflow_skill_md_constants.py +13 -0
- package/_shared/pr-loop/scripts/pr_converge_skill_constants/.claude/CLAUDE.md +1 -0
- package/_shared/pr-loop/scripts/pr_converge_skill_constants/AGENTS.md +26 -0
- package/_shared/pr-loop/scripts/pr_converge_skill_constants/__init__.py +0 -0
- package/_shared/pr-loop/scripts/pr_converge_skill_constants/constants.py +69 -0
- package/_shared/pr-loop/scripts/run_codex_review.py +609 -0
- package/_shared/pr-loop/scripts/test__pr_converge_path_setup.py +30 -0
- package/_shared/pr-loop/scripts/test_check_bugbot_ci.py +312 -0
- package/_shared/pr-loop/scripts/test_check_convergence.py +438 -0
- package/_shared/pr-loop/scripts/test_check_convergence_availability.py +391 -0
- package/_shared/pr-loop/scripts/test_check_convergence_codex.py +517 -0
- package/_shared/pr-loop/scripts/test_check_convergence_contract.py +400 -0
- package/_shared/pr-loop/scripts/test_check_convergence_fixture.py +179 -0
- package/_shared/pr-loop/scripts/test_check_convergence_gates.py +84 -0
- package/_shared/pr-loop/scripts/test_check_convergence_thread_gates.py +99 -0
- package/_shared/pr-loop/scripts/test_codex_down_classifier.py +143 -0
- package/_shared/pr-loop/scripts/test_codex_usage_probe.py +683 -0
- package/_shared/pr-loop/scripts/test_parse_codex_findings.py +130 -0
- package/_shared/pr-loop/scripts/test_run_codex_review.py +969 -0
- package/_shared/pr-loop/scripts/tests/test_claude_permissions_common.py +1 -1
- package/_shared/pr-loop/scripts/tests/test_code_rules_gate.py +1 -1
- package/_shared/pr-loop/scripts/tests/test_fix_hookspath.py +1 -1
- package/_shared/pr-loop/state-schema.md +20 -28
- package/_shared/pr-loop/worker-spawn.md +4 -3
- package/_shared/process-tree/AGENTS.md +3 -3
- package/bin/ever-shipped-skills.mjs +29 -1
- package/bin/install-constants.mjs +15 -6
- package/bin/install.agents-home.test.mjs +13 -0
- package/bin/install.cursor-rules.test.mjs +3 -3
- package/bin/install.mjs +80 -20
- package/bin/install.profile-root.test.mjs +1 -1
- package/bin/install.prune.test.mjs +23 -204
- package/bin/install.test.mjs +8 -5
- package/bin/resolve-install-root.mjs +21 -0
- package/bin/resolve-package-managed-directory.mjs +4 -4
- package/commands/AGENTS.md +2 -0
- package/commands/sr-loop.md +3 -0
- package/docs/references/prose-style-enforcement.md +3 -7
- package/docs/references/team-advisor-skill.md +2 -2
- package/hooks/AGENTS.md +0 -3
- package/hooks/blocking/AGENTS.md +0 -2
- package/hooks/blocking/ask_user_question_shape_blocker.py +83 -0
- package/hooks/blocking/pre_tool_use_dispatcher.py +2 -19
- package/hooks/blocking/state_description_blocker.py +1 -1
- package/hooks/blocking/test_ask_user_question_shape.py +69 -0
- package/hooks/blocking/test_pre_tool_use_dispatcher.py +17 -58
- package/hooks/blocking/test_pre_tool_use_dispatcher_native.py +9 -104
- package/hooks/blocking/test_state_description_blocker.py +1 -0
- package/hooks/blocking/test_stop_dispatcher.py +1 -26
- package/hooks/hooks.json +1 -1
- package/hooks/hooks_constants/AGENTS.md +0 -3
- package/hooks/hooks_constants/ask_user_question_shape.py +1 -1
- package/hooks/hooks_constants/ask_user_question_shape_constants.py +73 -0
- package/hooks/hooks_constants/bot_mention_comment_blocker_constants.py +1 -2
- package/hooks/hooks_constants/code_rules_path_utils_constants.py +0 -1
- package/hooks/hooks_constants/pre_tool_use_dispatcher_constants.py +0 -7
- package/hooks/hooks_constants/stop_dispatcher_constants.py +0 -1
- package/hooks/hooks_constants/test_ask_user_question_shape.py +1 -1
- package/hooks/hooks_constants/test_prose_metrics_parity.py +29 -107
- package/hooks/hooks_constants/test_stop_dispatcher_constants.py +0 -1
- package/hooks/hooks_constants/working_style_prompt_constants.py +9 -10
- package/hooks/session/AGENTS.md +4 -1
- package/hooks/session/test_working_style_prompt.py +8 -4
- package/hooks/session/working_style_prompt.py +4 -2
- package/package.json +1 -4
- package/rules/AGENTS.md +2 -5
- package/rules/asd-ste100-language.md +39 -0
- package/rules/ask-user-question-required.md +1 -1
- package/rules/long-horizon-autonomy.md +1 -1
- package/scripts/AGENTS.md +1 -0
- package/scripts/Show-Asset.ps1 +106 -0
- package/scripts/test_validate_instruction_pairs.py +30 -3
- package/scripts/tests/test_engine.py +4 -4
- package/scripts/tests/test_rules.py +5 -5
- package/system-prompts/AGENTS.md +8 -0
- package/system-prompts/software-engineer.xml +8 -3
- package/.agents/skills/grokify/evals/README.md +0 -72
- package/.agents/skills/grokify/evals/parse-payload.test.mjs +0 -171
- package/.agents/skills/grokify/evals/run-capability-evals.mjs +0 -545
- package/_shared/pr-loop/scripts/README.md +0 -21
- package/docs/imagegen.md +0 -22
- package/hooks/blocking/eli11_reply_enforcer.py +0 -436
- package/hooks/blocking/plain_language_blocker.py +0 -758
- package/hooks/blocking/test_eli11_reply_enforcer.py +0 -390
- package/hooks/blocking/test_plain_language_blocker.py +0 -683
- package/hooks/blocking/test_plain_language_blocker_allowlist.py +0 -228
- package/hooks/diagnostic/AGENTS.md +0 -75
- package/hooks/diagnostic/CLAUDE.md +0 -1
- package/hooks/diagnostic/hook_log_extractor.py +0 -875
- package/hooks/diagnostic/hook_log_init.py +0 -202
- package/hooks/diagnostic/hook_log_stop_wrapper.py +0 -26
- package/hooks/diagnostic/migrations/2026-04-25-drop-themes-hook-events.sql +0 -3
- package/hooks/diagnostic/migrations/AGENTS.md +0 -16
- package/hooks/diagnostic/migrations/CLAUDE.md +0 -1
- package/hooks/diagnostic/migrations/README.md +0 -76
- package/hooks/diagnostic/queries/AGENTS.md +0 -19
- package/hooks/diagnostic/queries/CLAUDE.md +0 -1
- package/hooks/diagnostic/queries/block_details_for_hook.sql +0 -26
- package/hooks/diagnostic/queries/blocks_by_category.sql +0 -10
- package/hooks/diagnostic/queries/blocks_by_tool.sql +0 -9
- package/hooks/diagnostic/queries/blocks_last_7_days.sql +0 -11
- package/hooks/diagnostic/queries/top_blockers_last_24_hours.sql +0 -12
- package/hooks/diagnostic/queries/top_blockers_overall.sql +0 -12
- package/hooks/diagnostic/requirements-hook-logs-dev.txt +0 -2
- package/hooks/diagnostic/requirements-hook-logs.txt +0 -1
- package/hooks/diagnostic/schema.sql +0 -51
- package/hooks/diagnostic/test_hook_log_extractor.py +0 -1518
- package/hooks/diagnostic/test_hook_log_init.py +0 -227
- package/hooks/diagnostic/test_hook_log_stop_wrapper.py +0 -17
- package/hooks/hooks_constants/eli11_reply_enforcer_constants.py +0 -94
- package/hooks/hooks_constants/hook_log_extractor_constants.py +0 -233
- package/hooks/hooks_constants/plain_language_blocker_constants.py +0 -366
- package/hooks/hooks_constants/test_hook_log_extractor_constants.py +0 -123
- package/rules/doc-prose-cuts.md +0 -58
- package/rules/eli11-replies.md +0 -36
- package/rules/opus5-communication-contract.md +0 -45
- package/rules/plain-language.md +0 -9
- /package/.agents/{skills → skills-archived}/anthropic-plan/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/scripts/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/scripts/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/scripts/anthropic_plan_scripts_constants/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/scripts/anthropic_plan_scripts_constants/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/scripts/anthropic_plan_scripts_constants/__init__.py +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/scripts/anthropic_plan_scripts_constants/validate_packet_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/scripts/test_validate_packet.py +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/scripts/validate_packet.py +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/templates/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/templates/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/templates/README.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/templates/build-prompt.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/templates/reuse-audit.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/templates/source-map.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/templates/visual-plan.template.html +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/test_skill_contract.py +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/workflow/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/workflow/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/workflow/plan-packet.contract.test.mjs +0 -0
- /package/.agents/{skills → skills-archived}/anthropic-plan/workflow/plan-packet.mjs +0 -0
- /package/.agents/{skills → skills-archived}/auditing-claude-config/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/auditing-claude-config/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/auditing-claude-config/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/auditing-claude-config/reference/probe-hook.md +0 -0
- /package/.agents/{skills → skills-archived}/beat-sheet/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/beat-sheet/reference/visual-beats.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/CONSTRAINTS.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/EXAMPLES.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/PROMPTS.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/README.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/audit-and-teammates.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/copilot-gap-analysis.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/design-rationale.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/github-pr-reviews.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/audit-assign-ids.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/audit-capture-excerpts.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/audit-walk-categories.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/audit-write-xml.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-append-summary.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-apply-fixes.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-git-add-commit.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-git-push.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-post-reply.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-publish-summary.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-py-compile.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-read-files.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-resolve-thread.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-test-suite.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-violation-count.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/obstacles/fix-write-xml.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/reference/team-setup.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/README.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/bugteam_code_rules_gate.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/bugteam_fix_hookspath.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/bugteam_preflight.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/bugteam_scripts_constants/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/bugteam_scripts_constants/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/bugteam_scripts_constants/__init__.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/bugteam_scripts_constants/probe_code_rules_enforcer_check_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/bugteam_scripts_constants/reflow_skill_md_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/bugteam_scripts_constants/windows_safe_rmtree_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/probe_code_rules_enforcer_check.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/test_bugteam_code_rules_gate.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/test_bugteam_fix_hookspath.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/test_bugteam_preflight.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/test_probe_code_rules_enforcer_check.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/test_windows_safe_rmtree.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/scripts/windows_safe_rmtree.py +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/sources.md +0 -0
- /package/.agents/{skills → skills-archived}/bugteam/test_skill_additions.py +0 -0
- /package/.agents/{skills → skills-archived}/closeout/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/closeout/reference/handoff-prompt-template.md +0 -0
- /package/.agents/{skills → skills-archived}/closeout/reference/pii-redaction-checklist.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/reference/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/reference/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/reference/cli-contract.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/reference/loop-integration.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/codex_down_classifier.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/codex_review_scripts_constants/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/codex_review_scripts_constants/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/codex_review_scripts_constants/__init__.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/codex_review_scripts_constants/classifier_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/codex_review_scripts_constants/codex_usage_probe_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/codex_review_scripts_constants/findings_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/codex_review_scripts_constants/run_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/codex_usage_probe.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/fixtures/auth_failure_synthetic.txt +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/fixtures/config_load_failure_v0.125.0.txt +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/fixtures/freeform_findings_v0.144.3.txt +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/fixtures/model_rejection_v0.125.0.jsonl +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/fixtures/structured_findings.txt +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/fixtures/success_stream_v0.144.3.jsonl +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/fixtures/unknown_failure_synthetic.txt +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/fixtures/usage_limit_synthetic.txt +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/parse_codex_findings.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/run_codex_review.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/test_codex_down_classifier.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/test_codex_usage_probe.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/test_parse_codex_findings.py +0 -0
- /package/.agents/{skills → skills-archived}/codex-review/scripts/test_run_codex_review.py +0 -0
- /package/.agents/{skills → skills-archived}/comments/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/condensing-instructions/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/copilot-finding-triage/reference/tier-rubric.md +0 -0
- /package/.agents/{skills → skills-archived}/copilot-finding-triage/scripts/conftest.py +0 -0
- /package/.agents/{skills → skills-archived}/copilot-finding-triage/scripts/copilot_finding_triage_constants/__init__.py +0 -0
- /package/.agents/{skills → skills-archived}/copilot-finding-triage/scripts/copilot_finding_triage_constants/config/__init__.py +0 -0
- /package/.agents/{skills → skills-archived}/copilot-finding-triage/scripts/copilot_finding_triage_constants/config/notify_ntfy_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/copilot-finding-triage/scripts/notify_ntfy.py +0 -0
- /package/.agents/{skills → skills-archived}/copilot-finding-triage/scripts/test_notify_ntfy.py +0 -0
- /package/.agents/{skills → skills-archived}/copilot-finding-triage/templates/notification.md +0 -0
- /package/.agents/{skills → skills-archived}/copilot-review/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/copilot-review/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/copilot-review/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/copilot-review/templates/subagent-prompt.md +0 -0
- /package/.agents/{skills → skills-archived}/descriptions/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/emergencies/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/grokify/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/grokify/capability-claims.test.mjs +0 -0
- /package/.agents/{skills → skills-archived}/grokify/templates/handoff-template.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/final-validation-tasks.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/model-routing.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/packet-contract.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/packet-schema.json +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/process-inventory.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/review-loop.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/run-record.schema.json +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/self-audit-tasks.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/task-seeds.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/reference/task-ticket.md +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/config/__init__.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/config/constants.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/create_packet.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/load_skill_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/test_create_packet.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/test_validate_packet.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/test_validate_protocol.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/test_validate_run.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/validate_packet.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/validate_protocol.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/scripts/validate_run.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/test_skill_contract.py +0 -0
- /package/.agents/{skills → skills-archived}/plan-to-pr/test_task_ticket_contract.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/pr_converge_skill_constants/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/pr_converge_skill_constants/__init__.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/convergence-gates.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/examples.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/fix-protocol.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/ground-rules.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-post-replies.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-publish-summary.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-push.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-read-filelines.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-reset-state.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-resolve-threads.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-spawn-clean-coder.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-stage-commit.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-trigger-bugbot.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/obstacles/fix-write-test.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/progress-checklist.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/state-schema.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/reference/stop-conditions.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/README.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/_pr_converge_path_setup.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/caller-window-pid.ps1 +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/check_bugbot_ci.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/check_convergence.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/check_convergence_availability.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/check_convergence_gates.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/check_convergence_thread_gates.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/check_pending_reviews.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/conftest.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/cursor-agents-continue-caller.cmd +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/cursor-agents-continue-stop-others.ps1 +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/cursor-agents-continue.ahk +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/cursor-agents-continue.cmd +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/fetch_copilot_reviews.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/post_fix_reply.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/pr_converge_scripts_constants/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/pr_converge_scripts_constants/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/pr_converge_scripts_constants/__init__.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/pr_converge_scripts_constants/convergence_gate_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/pr_converge_scripts_constants/pr_converge_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/pr_converge_scripts_constants/reflow_skill_md_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test__pr_converge_path_setup.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_check_bugbot_ci.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_check_convergence.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_check_convergence_availability.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_check_convergence_codex.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_check_convergence_contract.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_check_convergence_fixture.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_check_convergence_gates.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_check_convergence_thread_gates.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_cursor_agents_continue.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/scripts/test_reflow_skill_md.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/test_step5_host_branch.py +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/workflows/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-converge/workflows/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-fix-protocol/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-loop-cloud-transport/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-loop-cloud-transport/reference/identity-and-hooks.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-loop-cloud-transport/reference/substitution-matrix.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-loop-lifecycle/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/pr-loop-lifecycle/reference/teardown-publish-permissions.md +0 -0
- /package/.agents/{skills → skills-archived}/recall/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/recall/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/recall/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/release-notes-html/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/remember/.claude/CLAUDE.md +0 -0
- /package/.agents/{skills → skills-archived}/remember/AGENTS.md +0 -0
- /package/.agents/{skills → skills-archived}/remember/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/reviewer-gates/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/reviews/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/show/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/accessibility.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/art.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/charts.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/core-design.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/erds.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/flowcharts.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/host-and-html.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/illustrative-diagrams.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/interaction.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/mockups.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/quality-gates.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/structural-diagrams.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/subject-inventory.md +0 -0
- /package/.agents/{skills → skills-archived}/show/references/svg-contract.md +0 -0
- /package/.agents/{skills → skills-archived}/show/routing.yaml +0 -0
- /package/.agents/{skills → skills-archived}/show/samples/pr1262-v2.svg +0 -0
- /package/.agents/{skills → skills-archived}/show/scripts/README.md +0 -0
- /package/.agents/{skills → skills-archived}/show/scripts/validate-artifact.py +0 -0
- /package/.agents/{skills → skills-archived}/show/scripts/validate-package.py +0 -0
- /package/.agents/{skills → skills-archived}/show/templates/html-widget.html +0 -0
- /package/.agents/{skills → skills-archived}/show/templates/svg-base.svg +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/fixtures/css-var.svg +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/fixtures/dead-ref.svg +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/fixtures/filled-glyph.svg +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/fixtures/inherited-fill.svg +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/fixtures/invalid.svg +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/fixtures/large-canvas.svg +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/fixtures/unfilled-connector.svg +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/fixtures/valid.html +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/test_validate-artifact.py +0 -0
- /package/.agents/{skills → skills-archived}/show/tests/test_validators.py +0 -0
- /package/.agents/{skills → skills-archived}/show/workflows/create-visual.md +0 -0
- /package/.agents/{skills → skills-archived}/show/workflows/review-visual.md +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/SKILL.md +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/reference/path-layers.md +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/reference/split-further-loop.md +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/reference/splitting-principles.md +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/analyze_pr.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/categorize_files.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/config/__init__.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/config/dependency_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/config/git_operations_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/config/packing_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/config/plan_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/config/split_pr_constants.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/execute_split_slices.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/pack_files_into_slices.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/split_pr_dependency_graph.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/split_pr_git_operations.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/split_pr_layer_order.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/split_pr_paginate.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/split_pr_process_runner.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/split_pr_script_types.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/split_pr_title.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_analyze_pr.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_categorize_files.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_categorize_files_packing.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_execute_split_slices.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_split_pr_dependency_graph.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_split_pr_git_operations.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_split_pr_layer_order.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_split_pr_paginate.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_split_pr_script_types.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_split_pr_title.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_verify_dependency_graph.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_verify_plan.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_verify_plan_contract.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/test_verify_plan_path_normalization.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/verify_dependency_graph.py +0 -0
- /package/.agents/{skills → skills-archived}/split-pr/scripts/verify_plan.py +0 -0
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
"""Review-thread and pending-reviewer IO leaves for the convergence gate checks.
|
|
2
|
+
|
|
3
|
+
Each function issues one ``gh`` call (GraphQL or REST) and returns a
|
|
4
|
+
``(passed, detail)`` pair the convergence checker turns into a PASS/FAIL line.
|
|
5
|
+
The checker re-imports these names, so a test patches them on the checker module.
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
from __future__ import annotations
|
|
9
|
+
|
|
10
|
+
import json
|
|
11
|
+
|
|
12
|
+
import _pr_converge_path_setup # noqa: F401
|
|
13
|
+
from check_convergence_gates import (
|
|
14
|
+
JsonObject,
|
|
15
|
+
ReviewStateGroup,
|
|
16
|
+
_gh_api,
|
|
17
|
+
_run_gh_command,
|
|
18
|
+
)
|
|
19
|
+
from pr_converge_skill_constants.constants import (
|
|
20
|
+
CLAUDE_LOGIN_FILTER_SUBSTRING,
|
|
21
|
+
COPILOT_LOGIN_FILTER_SUBSTRING,
|
|
22
|
+
COPILOT_REVIEWER_LOGIN,
|
|
23
|
+
CURSOR_LOGIN_FILTER_SUBSTRING,
|
|
24
|
+
GH_REQUESTED_REVIEWERS_PATH_TEMPLATE,
|
|
25
|
+
GRAPHQL_REVIEW_THREADS_PAGE_SIZE,
|
|
26
|
+
UNRESOLVED_THREAD_DETAIL_MAX,
|
|
27
|
+
)
|
|
28
|
+
from pr_converge_scripts_constants.convergence_gate_constants import (
|
|
29
|
+
GRAPHQL_REVIEW_THREADS_QUERY,
|
|
30
|
+
PENDING_REVIEWER_JOIN_SEPARATOR,
|
|
31
|
+
THREAD_PATH_JOIN_SEPARATOR,
|
|
32
|
+
)
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
def _gh_graphql(query: str, variables: JsonObject) -> tuple[int, str]:
|
|
36
|
+
"""Run a ``gh api graphql`` query with variables and return returncode and stdout."""
|
|
37
|
+
all_arguments: list[str] = ["gh", "api", "graphql", "-f", f"query={query}"]
|
|
38
|
+
for each_key, each_variable in variables.items():
|
|
39
|
+
if each_variable is None:
|
|
40
|
+
continue
|
|
41
|
+
flag = "-F" if isinstance(each_variable, int) else "-f"
|
|
42
|
+
all_arguments.extend([flag, f"{each_key}={each_variable}"])
|
|
43
|
+
return _run_gh_command(all_arguments)
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
def _thread_author_login(thread: JsonObject) -> str:
|
|
47
|
+
"""Return the login of a review thread's first comment author, or empty string."""
|
|
48
|
+
comments_wrapper = thread.get("comments", {})
|
|
49
|
+
if not isinstance(comments_wrapper, dict):
|
|
50
|
+
return ""
|
|
51
|
+
comments_nodes = comments_wrapper.get("nodes", [])
|
|
52
|
+
if not isinstance(comments_nodes, list) or not comments_nodes:
|
|
53
|
+
return ""
|
|
54
|
+
first_comment = comments_nodes[0]
|
|
55
|
+
author_wrapper = (
|
|
56
|
+
first_comment.get("author") if isinstance(first_comment, dict) else None
|
|
57
|
+
)
|
|
58
|
+
if not isinstance(author_wrapper, dict):
|
|
59
|
+
return ""
|
|
60
|
+
login = author_wrapper.get("login", "")
|
|
61
|
+
return login if isinstance(login, str) else ""
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
def _is_unresolved_bot_thread(thread: JsonObject, bot_logins: ReviewStateGroup) -> bool:
|
|
65
|
+
"""Return whether a review thread is unresolved, current, and bot-authored."""
|
|
66
|
+
if thread.get("isResolved") is True or thread.get("isOutdated") is True:
|
|
67
|
+
return False
|
|
68
|
+
login = _thread_author_login(thread).lower()
|
|
69
|
+
return any(each_bot in login for each_bot in bot_logins)
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
def _unresolved_bot_threads_in_page(
|
|
73
|
+
nodes: object, bot_logins: ReviewStateGroup
|
|
74
|
+
) -> list[JsonObject]:
|
|
75
|
+
"""Return the unresolved bot-authored threads among one page of thread nodes."""
|
|
76
|
+
if not isinstance(nodes, list):
|
|
77
|
+
return []
|
|
78
|
+
return [
|
|
79
|
+
each_thread
|
|
80
|
+
for each_thread in nodes
|
|
81
|
+
if isinstance(each_thread, dict)
|
|
82
|
+
and _is_unresolved_bot_thread(each_thread, bot_logins)
|
|
83
|
+
]
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
def _review_threads_container(graphql_payload: object) -> JsonObject | None:
|
|
87
|
+
"""Return the ``reviewThreads`` object from a GraphQL payload, or None."""
|
|
88
|
+
if not isinstance(graphql_payload, dict):
|
|
89
|
+
return None
|
|
90
|
+
envelope = graphql_payload.get("data", {})
|
|
91
|
+
repository = envelope.get("repository", {}) if isinstance(envelope, dict) else {}
|
|
92
|
+
pull_request = (
|
|
93
|
+
repository.get("pullRequest", {}) if isinstance(repository, dict) else {}
|
|
94
|
+
)
|
|
95
|
+
threads = (
|
|
96
|
+
pull_request.get("reviewThreads", {}) if isinstance(pull_request, dict) else {}
|
|
97
|
+
)
|
|
98
|
+
return threads if isinstance(threads, dict) else None
|
|
99
|
+
|
|
100
|
+
|
|
101
|
+
def _fetch_review_threads_page(
|
|
102
|
+
*, owner: str, repo: str, number: int, cursor: str | None
|
|
103
|
+
) -> tuple[str, object, object]:
|
|
104
|
+
"""Fetch one page of review threads and return an error text, nodes, and page info."""
|
|
105
|
+
variables: JsonObject = {
|
|
106
|
+
"owner": owner,
|
|
107
|
+
"repo": repo,
|
|
108
|
+
"number": number,
|
|
109
|
+
"first": GRAPHQL_REVIEW_THREADS_PAGE_SIZE,
|
|
110
|
+
"cursor": cursor,
|
|
111
|
+
}
|
|
112
|
+
returncode, stdout = _gh_graphql(GRAPHQL_REVIEW_THREADS_QUERY, variables)
|
|
113
|
+
if returncode != 0:
|
|
114
|
+
return f"gh api graphql error: {stdout}", [], {}
|
|
115
|
+
try:
|
|
116
|
+
graphql_payload = json.loads(stdout)
|
|
117
|
+
except json.JSONDecodeError:
|
|
118
|
+
return "gh api graphql response not valid JSON", [], {}
|
|
119
|
+
threads = _review_threads_container(graphql_payload)
|
|
120
|
+
if threads is None:
|
|
121
|
+
return "unexpected GraphQL response shape", [], {}
|
|
122
|
+
return "", threads.get("nodes", []), threads.get("pageInfo", {})
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
def _next_thread_cursor(page_info: object) -> str | None:
|
|
126
|
+
"""Return the next pagination cursor, or None when there is no next page."""
|
|
127
|
+
if not isinstance(page_info, dict):
|
|
128
|
+
return None
|
|
129
|
+
if not page_info.get("hasNextPage"):
|
|
130
|
+
return None
|
|
131
|
+
next_cursor = page_info.get("endCursor")
|
|
132
|
+
return next_cursor if isinstance(next_cursor, str) else None
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
def _format_unresolved_detail(all_unresolved: list[JsonObject]) -> str:
|
|
136
|
+
"""Format the unresolved-thread count and a bounded list of their paths."""
|
|
137
|
+
detail_parts = [
|
|
138
|
+
str(each_thread.get("path", "?"))
|
|
139
|
+
for each_thread in all_unresolved[:UNRESOLVED_THREAD_DETAIL_MAX]
|
|
140
|
+
]
|
|
141
|
+
detail_text = THREAD_PATH_JOIN_SEPARATOR.join(detail_parts)
|
|
142
|
+
if len(all_unresolved) > UNRESOLVED_THREAD_DETAIL_MAX:
|
|
143
|
+
detail_text += (
|
|
144
|
+
f" ... and {len(all_unresolved) - UNRESOLVED_THREAD_DETAIL_MAX} more"
|
|
145
|
+
)
|
|
146
|
+
return f"{len(all_unresolved)} unresolved ({detail_text})"
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
def _count_unresolved_bot_threads(
|
|
150
|
+
*, owner: str, repo: str, number: int
|
|
151
|
+
) -> tuple[bool, str]:
|
|
152
|
+
"""Return whether zero unresolved bot review threads remain on the PR."""
|
|
153
|
+
bot_logins = (
|
|
154
|
+
CURSOR_LOGIN_FILTER_SUBSTRING,
|
|
155
|
+
CLAUDE_LOGIN_FILTER_SUBSTRING,
|
|
156
|
+
COPILOT_LOGIN_FILTER_SUBSTRING,
|
|
157
|
+
)
|
|
158
|
+
all_unresolved: list[JsonObject] = []
|
|
159
|
+
cursor: str | None = None
|
|
160
|
+
while True:
|
|
161
|
+
error_text, nodes, page_info = _fetch_review_threads_page(
|
|
162
|
+
owner=owner, repo=repo, number=number, cursor=cursor
|
|
163
|
+
)
|
|
164
|
+
if error_text:
|
|
165
|
+
return False, error_text
|
|
166
|
+
all_unresolved.extend(_unresolved_bot_threads_in_page(nodes, bot_logins))
|
|
167
|
+
cursor = _next_thread_cursor(page_info)
|
|
168
|
+
if cursor is None:
|
|
169
|
+
break
|
|
170
|
+
if not all_unresolved:
|
|
171
|
+
return True, "0 unresolved"
|
|
172
|
+
return False, _format_unresolved_detail(all_unresolved)
|
|
173
|
+
|
|
174
|
+
|
|
175
|
+
def _requested_reviewer_users(pending_payload: object) -> list[object]:
|
|
176
|
+
if isinstance(pending_payload, dict):
|
|
177
|
+
users = pending_payload.get("users", [])
|
|
178
|
+
elif isinstance(pending_payload, list):
|
|
179
|
+
users = pending_payload
|
|
180
|
+
else:
|
|
181
|
+
return []
|
|
182
|
+
return users if isinstance(users, list) else []
|
|
183
|
+
|
|
184
|
+
|
|
185
|
+
def _pending_copilot_logins(all_users: list[object]) -> list[str]:
|
|
186
|
+
"""Return the Copilot reviewer logins still pending among requested reviewers."""
|
|
187
|
+
pending: list[str] = []
|
|
188
|
+
for each_user in all_users:
|
|
189
|
+
if not isinstance(each_user, dict):
|
|
190
|
+
continue
|
|
191
|
+
login = each_user.get("login", "")
|
|
192
|
+
if isinstance(login, str) and COPILOT_REVIEWER_LOGIN.lower() in login.lower():
|
|
193
|
+
pending.append(login)
|
|
194
|
+
return pending
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
def _check_no_pending_reviews(
|
|
198
|
+
*, owner: str, repo: str, number: int
|
|
199
|
+
) -> tuple[bool, str]:
|
|
200
|
+
"""Return whether no Copilot review request is still pending on the PR."""
|
|
201
|
+
endpoint = GH_REQUESTED_REVIEWERS_PATH_TEMPLATE.format(
|
|
202
|
+
owner=owner, repo=repo, number=number
|
|
203
|
+
)
|
|
204
|
+
returncode, stdout = _gh_api(endpoint)
|
|
205
|
+
if returncode != 0:
|
|
206
|
+
return False, f"gh api error: {stdout}"
|
|
207
|
+
try:
|
|
208
|
+
pending_payload = json.loads(stdout)
|
|
209
|
+
except json.JSONDecodeError:
|
|
210
|
+
return False, "pending-reviewers response not valid JSON"
|
|
211
|
+
copilot_pending = _pending_copilot_logins(
|
|
212
|
+
_requested_reviewer_users(pending_payload)
|
|
213
|
+
)
|
|
214
|
+
if copilot_pending:
|
|
215
|
+
return (
|
|
216
|
+
False,
|
|
217
|
+
f"pending: {PENDING_REVIEWER_JOIN_SEPARATOR.join(copilot_pending)}",
|
|
218
|
+
)
|
|
219
|
+
return True, "no pending reviewers"
|
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
"""Check for pending pull request reviews.
|
|
2
|
+
|
|
3
|
+
Usage:
|
|
4
|
+
python scripts/check_pending_reviews.py --owner <O> --repo <R> --pr-number <N> [--user <substring>]
|
|
5
|
+
|
|
6
|
+
Exit codes:
|
|
7
|
+
0 — pending review(s) found (printed to stdout as JSON array)
|
|
8
|
+
1 — no pending reviews found
|
|
9
|
+
EXIT_CODE_GH_ERROR — gh CLI error
|
|
10
|
+
"""
|
|
11
|
+
|
|
12
|
+
from __future__ import annotations
|
|
13
|
+
|
|
14
|
+
import argparse
|
|
15
|
+
import json
|
|
16
|
+
import subprocess
|
|
17
|
+
import sys
|
|
18
|
+
from pathlib import Path
|
|
19
|
+
|
|
20
|
+
_pr_converge_dir = Path(__file__).absolute().parent.parent
|
|
21
|
+
if str(_pr_converge_dir) not in sys.path:
|
|
22
|
+
sys.path.insert(0, str(_pr_converge_dir))
|
|
23
|
+
|
|
24
|
+
from pr_converge_skill_constants.constants import (
|
|
25
|
+
EXIT_CODE_GH_ERROR,
|
|
26
|
+
GH_REVIEWS_PATH_TEMPLATE,
|
|
27
|
+
REVIEWS_PER_PAGE,
|
|
28
|
+
)
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
def fetch_pending_reviews(
|
|
32
|
+
*, owner: str, repo: str, number: int, user_filter: str | None = None
|
|
33
|
+
) -> list[dict[str, object]]:
|
|
34
|
+
"""Fetch pending reviews for a pull request.
|
|
35
|
+
|
|
36
|
+
Args:
|
|
37
|
+
owner: GitHub repository owner.
|
|
38
|
+
repo: GitHub repository name.
|
|
39
|
+
number: Pull request number.
|
|
40
|
+
user_filter: Optional case-insensitive substring to match against user login.
|
|
41
|
+
|
|
42
|
+
Returns:
|
|
43
|
+
List of pending review entries.
|
|
44
|
+
|
|
45
|
+
Raises:
|
|
46
|
+
SystemExit: When the gh CLI call fails.
|
|
47
|
+
"""
|
|
48
|
+
endpoint_path = (
|
|
49
|
+
GH_REVIEWS_PATH_TEMPLATE.format(owner=owner, repo=repo, number=number)
|
|
50
|
+
+ f"?per_page={REVIEWS_PER_PAGE}"
|
|
51
|
+
)
|
|
52
|
+
completed_process = subprocess.run(
|
|
53
|
+
["gh", "api", endpoint_path, "--paginate", "--slurp"],
|
|
54
|
+
capture_output=True,
|
|
55
|
+
text=True,
|
|
56
|
+
encoding="utf-8",
|
|
57
|
+
errors="replace",
|
|
58
|
+
check=False,
|
|
59
|
+
)
|
|
60
|
+
if completed_process.returncode != 0:
|
|
61
|
+
print(f"gh api error: {completed_process.stderr}", file=sys.stderr)
|
|
62
|
+
raise SystemExit(EXIT_CODE_GH_ERROR)
|
|
63
|
+
raw_output: object = json.loads(completed_process.stdout)
|
|
64
|
+
if not isinstance(raw_output, list):
|
|
65
|
+
return []
|
|
66
|
+
all_pages: list[list[dict[str, object]]] = [
|
|
67
|
+
each_page for each_page in raw_output if isinstance(each_page, list)
|
|
68
|
+
]
|
|
69
|
+
all_flat: list[dict[str, object]] = [
|
|
70
|
+
each_item for each_page in all_pages for each_item in each_page
|
|
71
|
+
]
|
|
72
|
+
pending_reviews: list[dict[str, object]] = []
|
|
73
|
+
for each_review in all_flat:
|
|
74
|
+
if each_review.get("state") != "PENDING":
|
|
75
|
+
continue
|
|
76
|
+
user_object: object = each_review.get("user")
|
|
77
|
+
user_login: str = ""
|
|
78
|
+
if isinstance(user_object, dict):
|
|
79
|
+
raw_login: object = user_object.get("login")
|
|
80
|
+
if isinstance(raw_login, str):
|
|
81
|
+
user_login = raw_login
|
|
82
|
+
raw_submitted: object = each_review.get("submitted_at")
|
|
83
|
+
submitted_at: str = ""
|
|
84
|
+
if isinstance(raw_submitted, str):
|
|
85
|
+
submitted_at = raw_submitted
|
|
86
|
+
raw_commit: object = each_review.get("commit_id")
|
|
87
|
+
commit_short: str = ""
|
|
88
|
+
if isinstance(raw_commit, str):
|
|
89
|
+
commit_short = raw_commit[:7]
|
|
90
|
+
if user_filter is not None and user_filter.lower() not in user_login.lower():
|
|
91
|
+
continue
|
|
92
|
+
pending_reviews.append(
|
|
93
|
+
{
|
|
94
|
+
"user": user_login,
|
|
95
|
+
"submitted_at": submitted_at,
|
|
96
|
+
"commit_id": commit_short,
|
|
97
|
+
}
|
|
98
|
+
)
|
|
99
|
+
return pending_reviews
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
def parse_arguments(all_argv: list[str]) -> argparse.Namespace:
|
|
103
|
+
"""Parse command-line arguments.
|
|
104
|
+
|
|
105
|
+
Args:
|
|
106
|
+
all_argv: Command-line argument list.
|
|
107
|
+
|
|
108
|
+
Returns:
|
|
109
|
+
Parsed namespace with owner, repo, and number.
|
|
110
|
+
"""
|
|
111
|
+
parser = argparse.ArgumentParser(description=__doc__)
|
|
112
|
+
parser.add_argument("--owner", required=True, help="GitHub repository owner")
|
|
113
|
+
parser.add_argument("--repo", required=True, help="GitHub repository name")
|
|
114
|
+
parser.add_argument("--pr-number", required=True, type=int, help="Pull request number")
|
|
115
|
+
parser.add_argument(
|
|
116
|
+
"--user",
|
|
117
|
+
default=None,
|
|
118
|
+
help="Optional case-insensitive substring filter for user login",
|
|
119
|
+
)
|
|
120
|
+
return parser.parse_args(all_argv)
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
def main(
|
|
124
|
+
all_arguments: list[str], *, user_filter: str | None = None
|
|
125
|
+
) -> int:
|
|
126
|
+
"""Entry point for check_pending_reviews.
|
|
127
|
+
|
|
128
|
+
Args:
|
|
129
|
+
all_arguments: Command-line arguments.
|
|
130
|
+
user_filter: Override for user filter (default: from CLI).
|
|
131
|
+
|
|
132
|
+
Returns:
|
|
133
|
+
0 when pending reviews are found, 1 when none, EXIT_CODE_GH_ERROR on error.
|
|
134
|
+
"""
|
|
135
|
+
arguments = parse_arguments(all_arguments)
|
|
136
|
+
if arguments.owner is None:
|
|
137
|
+
return 1
|
|
138
|
+
pending = fetch_pending_reviews(
|
|
139
|
+
owner=arguments.owner,
|
|
140
|
+
repo=arguments.repo,
|
|
141
|
+
number=getattr(arguments, "pr_number"),
|
|
142
|
+
user_filter=arguments.user if user_filter is None else user_filter,
|
|
143
|
+
)
|
|
144
|
+
if pending:
|
|
145
|
+
json.dump(pending, sys.stdout)
|
|
146
|
+
sys.stdout.write("\n")
|
|
147
|
+
return 0
|
|
148
|
+
return 1
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
if __name__ == "__main__":
|
|
152
|
+
all_argv = sys.argv[1:]
|
|
153
|
+
arguments = parse_arguments(all_argv)
|
|
154
|
+
raise SystemExit(main(all_argv, user_filter=arguments.user))
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
"""Classify Codex run streams into down-detail and gate outcome classes.
|
|
2
|
+
|
|
3
|
+
::
|
|
4
|
+
|
|
5
|
+
classification = classify_codex_run(exit_code=1, stream_text=stderr_text)
|
|
6
|
+
classification.detail_class # usage_limit | auth_failure | ...
|
|
7
|
+
classification.outcome_class # codex_down | completed
|
|
8
|
+
"""
|
|
9
|
+
|
|
10
|
+
from __future__ import annotations
|
|
11
|
+
|
|
12
|
+
from dataclasses import dataclass
|
|
13
|
+
|
|
14
|
+
from codex_review_scripts_constants.classifier_constants import (
|
|
15
|
+
ALL_AUTH_FAILURE_MARKERS,
|
|
16
|
+
ALL_CONFIG_ERROR_MARKERS,
|
|
17
|
+
ALL_MODEL_ERROR_MARKERS,
|
|
18
|
+
ALL_USAGE_LIMIT_MARKERS,
|
|
19
|
+
FAILURE_CLASS_AUTH_FAILURE,
|
|
20
|
+
FAILURE_CLASS_CONFIG_ERROR,
|
|
21
|
+
FAILURE_CLASS_MODEL_ERROR,
|
|
22
|
+
FAILURE_CLASS_UNKNOWN,
|
|
23
|
+
FAILURE_CLASS_USAGE_LIMIT,
|
|
24
|
+
SUCCESS_EXIT_CODE,
|
|
25
|
+
)
|
|
26
|
+
from codex_review_scripts_constants.run_constants import (
|
|
27
|
+
OUTCOME_CLASS_CODEX_DOWN,
|
|
28
|
+
OUTCOME_CLASS_COMPLETED,
|
|
29
|
+
)
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
@dataclass(frozen=True)
|
|
33
|
+
class CodexRunClassification:
|
|
34
|
+
"""Fine-grained failure class plus the gate-level outcome class.
|
|
35
|
+
|
|
36
|
+
::
|
|
37
|
+
|
|
38
|
+
CodexRunClassification(
|
|
39
|
+
detail_class="config_error",
|
|
40
|
+
outcome_class="codex_down",
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
Attributes:
|
|
44
|
+
detail_class: ``completed`` or a failure class name.
|
|
45
|
+
outcome_class: ``completed`` or ``codex_down`` for the conditional gate.
|
|
46
|
+
"""
|
|
47
|
+
|
|
48
|
+
detail_class: str
|
|
49
|
+
outcome_class: str
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
def _stream_contains_marker(stream_text: str, all_markers: tuple[str, ...]) -> bool:
|
|
53
|
+
lowered_stream = stream_text.lower()
|
|
54
|
+
return any(each_marker in lowered_stream for each_marker in all_markers)
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
def _classify_failure_detail(stream_text: str) -> str:
|
|
58
|
+
if _stream_contains_marker(stream_text, ALL_CONFIG_ERROR_MARKERS):
|
|
59
|
+
return FAILURE_CLASS_CONFIG_ERROR
|
|
60
|
+
if _stream_contains_marker(stream_text, ALL_MODEL_ERROR_MARKERS):
|
|
61
|
+
return FAILURE_CLASS_MODEL_ERROR
|
|
62
|
+
if _stream_contains_marker(stream_text, ALL_USAGE_LIMIT_MARKERS):
|
|
63
|
+
return FAILURE_CLASS_USAGE_LIMIT
|
|
64
|
+
if _stream_contains_marker(stream_text, ALL_AUTH_FAILURE_MARKERS):
|
|
65
|
+
return FAILURE_CLASS_AUTH_FAILURE
|
|
66
|
+
return FAILURE_CLASS_UNKNOWN
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
def classify_codex_run(*, exit_code: int, stream_text: str) -> CodexRunClassification:
|
|
70
|
+
"""Map exit code and stream text to detail and gate outcome classes.
|
|
71
|
+
|
|
72
|
+
::
|
|
73
|
+
|
|
74
|
+
classify_codex_run(exit_code=0, stream_text=success_jsonl)
|
|
75
|
+
# ok: detail_class=completed, outcome_class=completed
|
|
76
|
+
classify_codex_run(exit_code=1, stream_text="rate limit")
|
|
77
|
+
# ok: detail_class=usage_limit, outcome_class=codex_down
|
|
78
|
+
|
|
79
|
+
Exit zero is a completed review. Every other class — including
|
|
80
|
+
``unknown`` for nonzero exits and unparseable text — maps to
|
|
81
|
+
``codex_down`` so the conditional gate fails closed.
|
|
82
|
+
|
|
83
|
+
Args:
|
|
84
|
+
exit_code: Process exit code from the Codex review invocation.
|
|
85
|
+
stream_text: Captured stdout JSONL and/or stderr text.
|
|
86
|
+
|
|
87
|
+
Returns:
|
|
88
|
+
Detail class and gate outcome class for the run.
|
|
89
|
+
"""
|
|
90
|
+
if exit_code == SUCCESS_EXIT_CODE:
|
|
91
|
+
return CodexRunClassification(
|
|
92
|
+
detail_class=OUTCOME_CLASS_COMPLETED,
|
|
93
|
+
outcome_class=OUTCOME_CLASS_COMPLETED,
|
|
94
|
+
)
|
|
95
|
+
return CodexRunClassification(
|
|
96
|
+
detail_class=_classify_failure_detail(stream_text),
|
|
97
|
+
outcome_class=OUTCOME_CLASS_CODEX_DOWN,
|
|
98
|
+
)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@../AGENTS.md
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# codex_review_scripts_constants
|
|
2
|
+
|
|
3
|
+
Python package of named constants imported by Codex review scripts under `_shared/pr-loop/scripts/`. Importing from this package keeps magic values out of script bodies.
|
|
4
|
+
|
|
5
|
+
## Modules
|
|
6
|
+
|
|
7
|
+
| File | Constants for |
|
|
8
|
+
|---|---|
|
|
9
|
+
| `__init__.py` | Package marker and package docstring. |
|
|
10
|
+
| `run_constants.py` | Binary name, flag strings, custom-instructions prompt, version-probe pattern, timeout default, decode/timeout exit sentinels, flag_token_pattern suffix (whole-token shape match), JSONL keys, and capture outcome class labels for `run_codex_review.py`. |
|
|
11
|
+
| `findings_constants.py` | Finding field keys, fenced-JSON and freeform patterns for `parse_codex_findings.py`. |
|
|
12
|
+
| `classifier_constants.py` | Failure class names and stream markers for `codex_down_classifier.py`. |
|
|
13
|
+
| `run_constants.py` | Binary name, flag strings, custom-instructions prompt, version-probe pattern, timeout default, decode/timeout exit sentinels, flag_token_pattern suffix (whole-token shape match), JSONL keys, JSONL capture filename and newline mode, and capture outcome class labels for `run_codex_review.py`. |
|
|
14
|
+
| `codex_usage_probe_constants.py` | The weekly-usage probe CLI: gate threshold, report JSON keys, app-server JSON-RPC surface, rate-limit field keys, weekly-window sizing, text-status parse patterns, source labels, and exit codes. |
|
|
15
|
+
|
|
16
|
+
## Convention
|
|
17
|
+
|
|
18
|
+
Scripts import from this package at module scope. No constant is defined inline in a script body — the hook enforces this at write time.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Named constants for Codex review scripts in _shared/pr-loop/scripts."""
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"""Named constants for the Codex down-classifier."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
FAILURE_CLASS_USAGE_LIMIT = "usage_limit"
|
|
6
|
+
FAILURE_CLASS_AUTH_FAILURE = "auth_failure"
|
|
7
|
+
FAILURE_CLASS_CONFIG_ERROR = "config_error"
|
|
8
|
+
FAILURE_CLASS_MODEL_ERROR = "model_error"
|
|
9
|
+
FAILURE_CLASS_UNKNOWN = "unknown"
|
|
10
|
+
ALL_CONFIG_ERROR_MARKERS = (
|
|
11
|
+
"error loading config.toml",
|
|
12
|
+
"unknown variant",
|
|
13
|
+
)
|
|
14
|
+
ALL_MODEL_ERROR_MARKERS = (
|
|
15
|
+
"invalid_request_error",
|
|
16
|
+
"model is not supported",
|
|
17
|
+
"requires a newer version of codex",
|
|
18
|
+
)
|
|
19
|
+
ALL_USAGE_LIMIT_MARKERS = (
|
|
20
|
+
"rate limit",
|
|
21
|
+
"too many requests",
|
|
22
|
+
"http 429",
|
|
23
|
+
" (429)",
|
|
24
|
+
"credits exhausted",
|
|
25
|
+
"out of credits",
|
|
26
|
+
"api quota",
|
|
27
|
+
"usage quota",
|
|
28
|
+
)
|
|
29
|
+
ALL_AUTH_FAILURE_MARKERS = (
|
|
30
|
+
"unauthorized",
|
|
31
|
+
"authentication failed",
|
|
32
|
+
"login required",
|
|
33
|
+
"not authenticated",
|
|
34
|
+
)
|
|
35
|
+
SUCCESS_EXIT_CODE = 0
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
"""Constants for the Codex weekly-usage probe CLI.
|
|
2
|
+
|
|
3
|
+
Groups: gate threshold, probe report JSON keys, app-server JSON-RPC surface,
|
|
4
|
+
rate-limit snapshot field keys, weekly-window sizing, parse patterns for
|
|
5
|
+
text status output, source labels, and exit codes.
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
from __future__ import annotations
|
|
9
|
+
|
|
10
|
+
WEEKLY_USAGE_GATE_THRESHOLD_PERCENT = 10
|
|
11
|
+
|
|
12
|
+
USAGE_REPORT_KEY_PERCENT_LEFT = "percent_left"
|
|
13
|
+
USAGE_REPORT_KEY_WINDOW_RESET = "window_reset"
|
|
14
|
+
USAGE_REPORT_KEY_SOURCE = "source"
|
|
15
|
+
|
|
16
|
+
CODEX_BINARY_NAME = "codex"
|
|
17
|
+
ALL_APP_SERVER_COMMAND_PARTS = ("app-server", "--listen", "stdio://")
|
|
18
|
+
APP_SERVER_TIMEOUT_SECONDS = 30
|
|
19
|
+
READER_THREAD_JOIN_TIMEOUT_SECONDS = 2
|
|
20
|
+
PROCESS_TREE_WAIT_TIMEOUT_SECONDS = 5
|
|
21
|
+
WINDOWS_OS_NAME = "nt"
|
|
22
|
+
WINDOWS_COMMAND_SHELL = "cmd"
|
|
23
|
+
WINDOWS_COMMAND_SHELL_RUN_FLAG = "/c"
|
|
24
|
+
ALL_WINDOWS_SCRIPT_SUFFIXES = (".cmd", ".bat")
|
|
25
|
+
|
|
26
|
+
JSONRPC_VERSION = "2.0"
|
|
27
|
+
JSONRPC_KEY_ID = "id"
|
|
28
|
+
JSONRPC_KEY_METHOD = "method"
|
|
29
|
+
JSONRPC_KEY_PARAMS = "params"
|
|
30
|
+
JSONRPC_KEY_REPLY_BODY = "result"
|
|
31
|
+
JSONRPC_KEY_ERROR = "error"
|
|
32
|
+
JSONRPC_KEY_VERSION = "jsonrpc"
|
|
33
|
+
|
|
34
|
+
INITIALIZE_REQUEST_ID = 1
|
|
35
|
+
RATE_LIMITS_REQUEST_ID = 2
|
|
36
|
+
METHOD_INITIALIZE = "initialize"
|
|
37
|
+
METHOD_INITIALIZED = "initialized"
|
|
38
|
+
METHOD_RATE_LIMITS_READ = "account/rateLimits/read"
|
|
39
|
+
|
|
40
|
+
CLIENT_INFO_KEY = "clientInfo"
|
|
41
|
+
CLIENT_INFO_NAME_KEY = "name"
|
|
42
|
+
CLIENT_INFO_VERSION_KEY = "version"
|
|
43
|
+
CLIENT_INFO_NAME = "codex-usage-probe"
|
|
44
|
+
CLIENT_INFO_VERSION = "1.0.0"
|
|
45
|
+
CAPABILITIES_KEY = "capabilities"
|
|
46
|
+
EXPERIMENTAL_API_KEY = "experimentalApi"
|
|
47
|
+
|
|
48
|
+
RATE_LIMITS_KEY = "rateLimits"
|
|
49
|
+
PRIMARY_WINDOW_KEY = "primary"
|
|
50
|
+
SECONDARY_WINDOW_KEY = "secondary"
|
|
51
|
+
USED_PERCENT_KEY = "usedPercent"
|
|
52
|
+
RESETS_AT_KEY = "resetsAt"
|
|
53
|
+
WINDOW_DURATION_MINS_KEY = "windowDurationMins"
|
|
54
|
+
|
|
55
|
+
WEEKLY_WINDOW_DURATION_MINUTES = 10080
|
|
56
|
+
PERCENT_FULL = 100
|
|
57
|
+
PERCENT_EMPTY = 0
|
|
58
|
+
|
|
59
|
+
SOURCE_APP_SERVER_RATE_LIMITS = "codex app-server account/rateLimits/read"
|
|
60
|
+
SOURCE_TEXT_STATUS = "text-status"
|
|
61
|
+
SOURCE_NO_USAGE_SURFACE = "no-usage-surface"
|
|
62
|
+
|
|
63
|
+
TEXT_WEEKLY_PERCENT_LEFT_PATTERN = (
|
|
64
|
+
r"(?i)weekly(?:\s+(?:limit|usage|cap))?"
|
|
65
|
+
r"[^\n%]{0,40}?"
|
|
66
|
+
r"(?P<percent>\d{1,3}(?:\.\d+)?)\s*%\s*(?:left|remaining)"
|
|
67
|
+
)
|
|
68
|
+
TEXT_WEEKLY_USED_PERCENT_PATTERN = (
|
|
69
|
+
r"(?i)weekly(?:\s+(?:limit|usage|cap))?"
|
|
70
|
+
r"[^\n%]{0,40}?"
|
|
71
|
+
r"(?P<percent>\d{1,3}(?:\.\d+)?)\s*%\s*(?:used|consumed)"
|
|
72
|
+
)
|
|
73
|
+
TEXT_WINDOW_RESET_PATTERN = (
|
|
74
|
+
r"(?i)(?:weekly\s+)?(?:window\s+)?resets?(?:\s+at)?"
|
|
75
|
+
r"[:\s]+(?P<reset>[^\s)\].,;]+)"
|
|
76
|
+
)
|
|
77
|
+
|
|
78
|
+
EXIT_CODE_SUCCESS = 0
|
|
79
|
+
EXIT_CODE_CRASH = 1
|
|
80
|
+
|
|
81
|
+
UTF8_ENCODING = "utf-8"
|
|
82
|
+
NEWLINE = "\n"
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"""Named constants for the Codex findings parser."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
FINDING_KEY_TITLE = "title"
|
|
6
|
+
FINDING_KEY_PRIORITY = "priority"
|
|
7
|
+
FINDING_KEY_FILE = "file"
|
|
8
|
+
FINDING_KEY_LINE_RANGE = "line_range"
|
|
9
|
+
FINDING_KEY_BODY = "body"
|
|
10
|
+
FENCED_JSON_BLOCK_PATTERN = r"```(?:json)?\s*\n(.*?)\n```"
|
|
11
|
+
FREEFORM_FINDING_LINE_PATTERN = (
|
|
12
|
+
r"^-\s*\[(?P<priority>P\d+)\]\s+"
|
|
13
|
+
r"(?P<title>.+?)\s+[—–-]\s+"
|
|
14
|
+
r"(?P<file_path>.+?):(?P<line_range>\d+-\d+)\s*$"
|
|
15
|
+
)
|
|
16
|
+
FREEFORM_BULLET_PREFIX = "- ["
|
|
17
|
+
EMPTY_STRING = ""
|
|
18
|
+
NEWLINE = "\n"
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"""Named constants for the Codex review headless wrapper."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
CODEX_BINARY_NAME = "codex"
|
|
6
|
+
EXEC_SUBCOMMAND = "exec"
|
|
7
|
+
REVIEW_SUBCOMMAND = "review"
|
|
8
|
+
HELP_FLAG = "--help"
|
|
9
|
+
VERSION_FLAG = "--version"
|
|
10
|
+
JSON_FLAG = "--json"
|
|
11
|
+
BASE_TARGET_FLAG = "--base"
|
|
12
|
+
UNCOMMITTED_TARGET_FLAG = "--uncommitted"
|
|
13
|
+
COMMIT_TARGET_FLAG = "--commit"
|
|
14
|
+
MODEL_FLAG = "-m"
|
|
15
|
+
CODEX_MODEL_PIN = ""
|
|
16
|
+
CODEX_HOME_ENV_VAR = "CODEX_HOME"
|
|
17
|
+
DEFAULT_TIMEOUT_SECONDS = 600
|
|
18
|
+
JSONL_CAPTURE_FILENAME = "codex-review.jsonl"
|
|
19
|
+
JSONL_CAPTURE_NEWLINE = ""
|
|
20
|
+
UTF8_ENCODING = "utf-8"
|
|
21
|
+
VERSION_PROBE_PATTERN = r"codex(?:-cli)?\s+(\d+\.\d+\.\d+)"
|
|
22
|
+
OUTCOME_CLASS_CODEX_DOWN = "codex_down"
|
|
23
|
+
OUTCOME_CLASS_COMPLETED = "completed"
|
|
24
|
+
MISSING_BINARY_EXIT_CODE = 127
|
|
25
|
+
TIMEOUT_EXIT_CODE = 124
|
|
26
|
+
SUBPROCESS_DECODE_EXIT_CODE = 70
|
|
27
|
+
CWD_KEYWORD = "cwd"
|
|
28
|
+
CAPTURE_STREAMS_KEYWORD = "capture_output"
|
|
29
|
+
TEXT_MODE_KEYWORD = "text"
|
|
30
|
+
ENCODING_KEYWORD = "encoding"
|
|
31
|
+
CHECK_KEYWORD = "check"
|
|
32
|
+
TIMEOUT_KEYWORD = "timeout"
|
|
33
|
+
ENVIRONMENT_KEYWORD = "env"
|
|
34
|
+
PROCESS_TREE_KILL_TIMEOUT_SECONDS = 10
|
|
35
|
+
SHAPE_FLAG_TOKEN_TAIL_PATTERN = r"(?![\w-])"
|
|
36
|
+
JSONL_EVENT_TYPE_KEY = "type"
|
|
37
|
+
JSONL_ENTRY_KEY = "item"
|
|
38
|
+
JSONL_ENTRY_COMPLETED_TYPE = "item.completed"
|
|
39
|
+
JSONL_AGENT_MESSAGE_TYPE = "agent_message"
|
|
40
|
+
JSONL_AGENT_MESSAGE_TEXT_KEY = "text"
|
|
41
|
+
CUSTOM_INSTRUCTIONS_PROMPT = (
|
|
42
|
+
"Write a one-line review summary, then the heading Review comment:, then "
|
|
43
|
+
"zero or more finding bullets. Each bullet must use the form "
|
|
44
|
+
"- [P1] <title> — <path>:<start>-<end> "
|
|
45
|
+
"followed by an explanation paragraph. Use the same [P#] priority tags. "
|
|
46
|
+
"When there are no findings, omit finding bullets after the summary."
|
|
47
|
+
)
|
|
48
|
+
ALL_SHAPE_PROBE_REQUIRED_FLAGS = (
|
|
49
|
+
BASE_TARGET_FLAG,
|
|
50
|
+
UNCOMMITTED_TARGET_FLAG,
|
|
51
|
+
COMMIT_TARGET_FLAG,
|
|
52
|
+
JSON_FLAG,
|
|
53
|
+
)
|