Skip to content

ci: lane-aware if:always() rollout for remaining 36 gating-lane steps (item 7) - #390

Merged
mixmansoundude merged 8 commits into
mainfrom
claude/pipreqs-fallback-maintenance-49jhr9
Jul 27, 2026
Merged

ci: lane-aware if:always() rollout for remaining 36 gating-lane steps (item 7)#390
mixmansoundude merged 8 commits into
mainfrom
claude/pipreqs-fallback-maintenance-49jhr9

Conversation

@mixmansoundude

Copy link
Copy Markdown
Owner

Summary

Follow-up to #389 (the item 7 scoping pass), driven to completion in the same sitting per direct instruction.

  • New Check Miniconda availability step (id: conda_avail, always(), a single Test-Path against the shared %PUBLIC%\Documents\Miniconda3\condabin\conda.bat — zero execution/network cost) placed right after the main bootstrap step.
  • 36 more steps converted to always(), each gated with a lane-aware condition (not a blanket one):
    • 22 steps restricted to real || conda-full: unconditional for real (uv-first lane, bounded redundant-retry cost via uv's own retry/timeout budget), gated on conda_avail only for conda-full (which unconditionally forces conda for the whole job).
    • 5 steps restricted to conda-full only: gated on conda_avail.
    • 9 steps that run on every non-corrupted lane: gated on conda_avail only for their conda-full executions.
  • Combined with the 5 zero-risk conversions from ci: convert 5 zero-risk gating-lane steps to if:always() (item 7 scoping pass) #389, 41 of the ~67 original candidate steps are now hardened. The remaining ~26 are each excluded for a specific, documented reason — not oversight:
    • 3 pre-bootstrap/setup steps that must run in order (the bootstrap step itself can't meaningfully be always()'d).
    • 2 load-bearing harness steps (tests/harness.ps1 has two throw sites on missing status files — converting these without hardening that first risks trading a clean skip for a confusing uncaught exception; flagged as a small, separate follow-up).
    • 2 steps restricted to the non-gating cache lane.

Full reasoning, the exact conditions per category, and the residual harness.ps1 note are recorded in CLAUDE.md's Active Backlog item 7.

Test plan

  • python -m compileall -q .
  • python tools/check_delimiters.py run_setup.bat
  • python -m yamllint .github/workflows/
  • actionlint -oneline .github/workflows/*.yml
  • ASCII sweep (no new non-ASCII introduced)
  • Scripted diff-scope check: exactly 36 if: lines changed, matching the 36 intended target steps, no stray edits
  • PowerShell AST parse sweep over tests/*.ps1, tools/*.ps1
  • python -m pytest tests/test_*.py -q (437 passed, 2 skipped)
  • Real Windows CI (this PR) — the one thing that can't be verified locally: does steps.conda_avail.outputs.available actually read as 'true'/'false' correctly in a real run, and does a genuine conda-full run (where conda IS available) behave identically to before

Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS


Generated by Claude Code

…teps

Owner-directed follow-up to the item 7 scoping pass ("if confidence is
high then proceed to next slice and drive to completion"). Adds a shared
"Check Miniconda availability" step (id: conda_avail, always(), a single
Test-Path against the shared %PUBLIC%\Documents\Miniconda3 install path,
zero execution/network cost) right after the main bootstrap step, then
converts 36 of the remaining candidate steps to always(), each gated
through it with a lane-aware condition rather than a uniform one:

- real/conda-full-restricted steps (22): unconditional for real (uv-first,
  bounded redundant-retry cost), gated on conda_avail for conda-full only.
- conda-full-only steps (5): gated on conda_avail.
- all-non-corrupted-lane steps (9): gated on conda_avail only for their
  conda-full executions.

Combined with the 5 zero-risk steps from the previous commit, 41 of the
~67 original candidate steps are now converted. The remaining ~26 are each
excluded for a specific, documented reason (pre-bootstrap ordering, a
harness.ps1 throw-on-missing-file risk, or the non-gating cache lane) --
not left over by oversight. Full reasoning and per-category conditions
recorded in CLAUDE.md.

Verified via yamllint/actionlint (clean) and a scripted diff-scope check
(exactly 36 if: lines changed, no stray edits) before committing.

Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

Co-authored-by: Claude <noreply@anthropic.com>
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@mixmansoundude
mixmansoundude enabled auto-merge (squash) July 26, 2026 18:46
@coderabbitai

coderabbitai Bot commented Jul 26, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

The workflow adds shared Miniconda detection, gates conda-dependent self-tests, and replaces many unconditional post-failure steps with cancellation-aware guards. Dynamic-test bootstrap failures now exit explicitly, while CLAUDE.md records the implementation scope and status.

Changes

Miniconda self-test gating

Layer / File(s) Summary
Availability probe and conda-dependent self-test gates
.github/workflows/batch-check.yml
Adds the conda_avail probe for primary and fallback Miniconda paths, then gates conda-dependent self-tests on its output across workflow stages.
Cancellation-aware self-test and diagnostics flow
.github/workflows/batch-check.yml
Replaces many always() guards with !cancelled() across self-tests, dynamic tests, reporting, iterate-gate handling, summaries, publishing, and diagnostics.
Dynamic-test failure signaling and hardening record
.github/workflows/batch-check.yml, CLAUDE.md
Reports bootstrap precondition failures with Write-Host and exit 1, and documents the implemented gating, cancellation handling, exclusions, and status accounting.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Sequence Diagram(s)

sequenceDiagram
  participant Bootstrap
  participant CondaProbe
  participant SelfTests
  participant Diagnostics
  Bootstrap->>CondaProbe: Check primary and fallback conda.bat paths
  CondaProbe-->>SelfTests: Return availability output
  SelfTests->>Diagnostics: Produce summaries, logs, and artifacts
  Diagnostics->>Diagnostics: Continue only when workflow is not cancelled
Loading
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the CI gating rollout and matches the main changes in the PR.
Description check ✅ Passed The description is detailed and directly describes the workflow and documentation changes in this PR.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/pipreqs-fallback-maintenance-49jhr9

Comment @coderabbitai help to get the list of available commands.

@mixmansoundude

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 26, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

CodeRabbit review on PR #390 caught this on the first real-CI pass: the
new "Check Miniconda availability" step only tested condabin\conda.bat,
but run_setup.bat's own :select_conda_bat (CONDA_MAIN/CONDA_ALT) and the
pre-existing "Validate restored conda binary" step both already treat
Scripts\conda.bat as an equally valid fallback. An install that only
landed via the fallback path would have made conda-full's own bootstrap
succeed while conda_avail wrongly reported "unavailable", silently
skipping every newly-gated conda-full self-test. Verified against
run_setup.bat directly before fixing (:select_conda_bat, lines ~1934-1938)
rather than taking the review comment on faith.

Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

Co-authored-by: Claude <noreply@anthropic.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
.github/workflows/batch-check.yml (1)

297-328: 🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win

Use !cancelled() for these self-test gates. always() keeps them running after a cancellation request, so aborted CI runs can still burn runner time on these long checks. Apply the same change to the other long-running self-tests in this job.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/batch-check.yml around lines 297 - 328, Replace always()
with !cancelled() in the if conditions for the shown self-test steps, including
“Self-test: single .py entry,” “Self-test: entry selection,” and “Self-test:
isolation and directory integrity.” Apply the same gate change to all other
long-running self-test steps in this job while preserving the existing
cache-corruption and conda availability conditions.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/batch-check.yml:
- Around line 290-294: Add exactly one focused regression test for the Miniconda
availability logic in the workflow step, covering both layouts separately: only
the $condaMain condabin path exists and only the $condaAlt Scripts fallback
exists. Assert that each layout produces the available=true output contract,
without adding additional feature changes or tests.

---

Outside diff comments:
In @.github/workflows/batch-check.yml:
- Around line 297-328: Replace always() with !cancelled() in the if conditions
for the shown self-test steps, including “Self-test: single .py entry,”
“Self-test: entry selection,” and “Self-test: isolation and directory
integrity.” Apply the same gate change to all other long-running self-test steps
in this job while preserving the existing cache-corruption and conda
availability conditions.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: ab3892d8-3cd5-4ee8-8706-3974c1320f6c

📥 Commits

Reviewing files that changed from the base of the PR and between ef7fa46 and 330b204.

📒 Files selected for processing (2)
  • .github/workflows/batch-check.yml
  • CLAUDE.md
📜 Review details
🧰 Additional context used
📓 Path-based instructions (3)
**/*.{bat,cmd,ps1,py,yml,yaml,json,md}

📄 CodeRabbit inference engine (CLAUDE.md)

Keep repository source and documentation ASCII-only; avoid emojis, curly quotes, and em dashes because non-ASCII characters can break batch/CMD parsing.

Files:

  • CLAUDE.md
**/*

📄 CodeRabbit inference engine (CLAUDE.md)

**/*: Update the relevant knowledge document in the same commit when a change teaches or invalidates a lesson: docs/agent-interconnect.md, docs/agent-lessons-learned.md, or docs/agent-ndjson.md.
Implement exactly one missing feature slice and add exactly one missing test per iteration loop; freeze scope and defer new requirements to the backlog.
Fix CI and pipeline/configuration errors before test errors, test assertions, and product code during an iteration loop.
Push every commit before it can be lost, especially before resetting or recreating a branch from origin/main.
Do not duplicate authoritative content from README.md, AGENTS.md, or CONTRIBUTING.md; reference those documents instead.

Files:

  • CLAUDE.md
.github/workflows/*.{yml,yaml}

📄 CodeRabbit inference engine (CLAUDE.md)

.github/workflows/*.{yml,yaml}: Validate modified workflow YAML with both yamllint and actionlint before committing.
Do not use PSGallery downloads in CI; use syntax-only validation where PowerShell dependencies would otherwise be required.

Files:

  • .github/workflows/batch-check.yml
🔇 Additional comments (3)
.github/workflows/batch-check.yml (2)

273-289: LGTM!


297-304: 🚀 Performance & Scalability

No issue: the real-lane self-tests don’t reopen the Miniconda installer. The workflow only probes the URL here; the actual download still happens once in the main bootstrap when CONDA_BAT is missing, and later steps reuse that shared install path.

			> Likely an incorrect or invalid review comment.
CLAUDE.md (1)

605-644: LGTM!

Also applies to: 630-639, 640-655

Comment thread .github/workflows/batch-check.yml
…bit)

CodeRabbit review on PR #390 flagged that always() keeps a step running
even after the workflow itself is cancelled (e.g. a newer push
superseding an in-flight run via this file's own cancel-in-progress
concurrency group), and recommended !cancelled() -- GitHub's own
documented idiom for "run regardless of prior step outcome, but respect
cancellation." Verified this generalizes cleanly to all 84 always()
occurrences in the selftest job (none hold/release any cross-run
resource), not just the 3 example steps CodeRabbit cited, and applied it
uniformly. Deliberately scoped to the selftest job only, matching the
review's own scope; the other 4 jobs in this file have 25 more always()
occurrences, not touched here.

Caught and fixed a second, self-inflicted bug via actionlint before this
shipped: a bare `if: !cancelled()` (no ${{ }} wrapper) fails to parse --
a leading ! is a YAML tag indicator, unlike always() which is safe
unwrapped since it starts with a letter. 17 of the 84 replacements were
bare and needed wrapping in ${{ !cancelled() }}; the other 67 were
already inside a compound ${{ ... }} expression.

Declined a third CodeRabbit suggestion (a dedicated regression test for
conda_avail's own dual-path Test-Path logic) as disproportionate scope
for a 4-line inline check with an already-untested precedent in the same
file (the "Validate restored conda binary" step's identical pattern).

Verified via yamllint/actionlint (clean) and an exact occurrence count
(84 always() removed, 84 !cancelled() added) before committing.

Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

Co-authored-by: Claude <noreply@anthropic.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/batch-check.yml:
- Line 286: Update the comment adjacent to the workflow step using the
!cancelled() condition so it accurately describes that the step runs after
failures but not when the workflow is cancelled; remove the stale Always()
reference.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 7eb7210f-347b-4c0f-b59a-1dad11c41e7b

📥 Commits

Reviewing files that changed from the base of the PR and between 330b204 and c7f3644.

📒 Files selected for processing (2)
  • .github/workflows/batch-check.yml
  • CLAUDE.md
📜 Review details
🧰 Additional context used
📓 Path-based instructions (2)
**/*

📄 CodeRabbit inference engine (CLAUDE.md)

**/*: When a change teaches or invalidates a lesson, update the relevant knowledge document in the same commit: interconnect dependencies, lessons learned, or NDJSON row registry.
Freeze scope for the current iteration loop; implement exactly one missing feature slice and add exactly one missing test per loop.
Use tilde-prefixed temporary files such as ~setup.log and ~bootstrap.status.json; these artifacts are gitignored and must not be renamed without the tilde.

Files:

  • CLAUDE.md
.github/workflows/**/*.{yml,yaml}

📄 CodeRabbit inference engine (CLAUDE.md)

Validate workflow YAML with yamllint, actionlint, and the repository's PyYAML checker.

Files:

  • .github/workflows/batch-check.yml
🔇 Additional comments (4)
CLAUDE.md (2)

678-681: Do not waive the required regression test (duplicate of the prior finding).

The dual-path conda_avail contract remains untested. Add exactly one focused test covering main-only and fallback-only layouts, asserting available=true.

As per coding guidelines, each loop must implement exactly one missing feature slice and add exactly one missing test.

Source: Coding guidelines


648-677: LGTM!

.github/workflows/batch-check.yml (2)

188-188: LGTM!

Also applies to: 203-203, 263-263, 273-277, 297-343, 370-414, 549-565, 675-783, 814-815, 846-847, 899-923, 938-938, 958-958, 1007-1007, 1014-1014, 1028-1028, 1046-1046, 1228-1228, 1237-1237, 1300-1300, 1328-1328, 1377-1377, 1883-1883, 1911-1911, 1930-1930, 1949-1949, 2015-2015, 2046-2046, 2060-2060, 2294-2294, 2306-2306, 2327-2327, 2339-2339, 2690-2690, 2699-2699, 2751-2751, 2841-2841, 2890-2890, 2899-2899, 2928-2928, 2957-2957, 2967-2967, 2985-2985


286-293: 🗄️ Data Integrity & Integration

PVW_CONDA_EXE does not bypass this CI gate This workflow never sets that override, so conda-full still follows the shared Miniconda paths checked by conda_avail.

			> Likely an incorrect or invalid review comment.

Comment thread .github/workflows/batch-check.yml
The step's own conditional was already correctly converted to !cancelled()
in the previous commit, but one explanatory comment line still said
"Always() so it runs..." -- my scripted always()->!cancelled() replace
was case-sensitive and missed this one capitalized instance. Caught by
CodeRabbit's re-review; no other capitalized "Always()" leftovers found
in a follow-up sweep.

The other two comments on this same review round were declined, same
reasoning as the prior commit: the dual-path conda_avail regression test
(disproportionate scope for a 4-line inline check with an already-
untested precedent) and a third finding CodeRabbit itself flagged as
"likely an incorrect or invalid review comment."

Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

Co-authored-by: Claude <noreply@anthropic.com>
Run dynamic tests (if present) and Run tests (map empty repo to success)
were the last two candidate steps from the item 7 scoping pass not yet
converted to !cancelled() -- flagged in CLAUDE.md as blocked on a throw
site needing hardening first. Re-reading the actual code before fixing it
found the blocker was misidentified: tests/harness.ps1's own two throw
sites are insulated by a genuine subprocess boundary (run_tests.bat
invokes powershell -File harness.ps1 as its own process, so an uncaught
throw there just becomes that process's exit code) -- Run tests (map
empty repo to success) was already safe to convert as-is.

The real risk was three throw statements inline in Run dynamic tests'
own PowerShell block, run in-process (not via a subprocess), reachable
for the first time once this step can run after an earlier Bootstrap
environment failure. Converted those three to Write-Host "::error::..."
+ exit 1 -- same failing outcome, no uncaught-exception stack trace.
Two later throws in the same step (dynamic_tests.bat/.py failed) are
untouched since they only fire once dynamic tests actually ran.

Both steps now carry !cancelled() && env.HP_CACHE_CORRUPTED != '1',
closing out the gating-lane half of Active Backlog item 7 completely.

Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

Co-authored-by: Claude <noreply@anthropic.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
CLAUDE.md (1)

605-628: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Update the stale always() documentation.

The shipped workflow uses !cancelled() for conda_avail and the converted steps, but this section still says the probe and 36 gates use always(). Update the examples and narrative to reflect the cancellation-aware conditions.

As per coding guidelines, update the relevant knowledge document when a change teaches or invalidates a lesson.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@CLAUDE.md` around lines 605 - 628, Update the workflow documentation section
describing conda_avail and the 36 converted steps to replace stale always()
references with the shipped !cancelled()-based conditions, including all gate
examples and narrative. Preserve the lane-specific conda_avail and
cache-corruption logic while documenting the cancellation-aware behavior
consistently.

Source: Coding guidelines

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@CLAUDE.md`:
- Around line 605-628: Update the workflow documentation section describing
conda_avail and the 36 converted steps to replace stale always() references with
the shipped !cancelled()-based conditions, including all gate examples and
narrative. Preserve the lane-specific conda_avail and cache-corruption logic
while documenting the cancellation-aware behavior consistently.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 3f3d09e4-a355-4e46-a5b3-faa501ee9a34

📥 Commits

Reviewing files that changed from the base of the PR and between c7f3644 and a644c2a.

📒 Files selected for processing (2)
  • .github/workflows/batch-check.yml
  • CLAUDE.md
📜 Review details
⏰ Context from checks skipped due to timeout. (8)
  • GitHub Check: Batch syntax/run check (conda-full)
  • GitHub Check: Batch syntax/run check (cache)
  • GitHub Check: Batch syntax/run check (contract-uv)
  • GitHub Check: Batch syntax/run check (uv-dl-fallback)
  • GitHub Check: Batch syntax/run check (uv)
  • GitHub Check: Batch syntax/run check (contract-uv-fail)
  • GitHub Check: Batch syntax/run check (justme-test)
  • GitHub Check: Batch syntax/run check (real)
🧰 Additional context used
📓 Path-based instructions (2)
**/*

📄 CodeRabbit inference engine (CLAUDE.md)

**/*: Update the relevant knowledge document in the same commit when a change teaches or invalidates a lesson; edit existing entries rather than only appending.
Implement exactly one missing feature slice and add exactly one missing test per iteration loop; freeze scope and defer new requirements to backlog.
Run the full sanity sweep before every commit, including Python compilation/linting, delimiter checks, workflow linting, PowerShell parsing, pytest, and an ASCII sweep covering changed files.

Files:

  • CLAUDE.md
.github/workflows/**/*.{yml,yaml}

📄 CodeRabbit inference engine (CLAUDE.md)

Validate modified GitHub Actions workflows with both yamllint and actionlint.

Files:

  • .github/workflows/batch-check.yml
🔇 Additional comments (2)
.github/workflows/batch-check.yml (2)

291-295: Add the required focused regression test.

The dual-path probe is now implemented, but the supplied change still does not add exactly one test covering the main-only and fallback-only layouts and asserting available=true. This is the same unresolved requirement from the previous review.

Source: Coding guidelines


188-264: LGTM!

Also applies to: 297-344, 371-415, 549-565, 675-784, 811-816, 846-848, 898-924, 939-960, 1004-1047, 1055-1056, 1091-1106, 1123-1124, 1188-1188, 1237-1246, 1309-1386, 1892-2069, 2288-2348, 2689-2760, 2839-2908, 2927-2985, 2994-2994

…lled()

The conda_avail probe and 36-step conversion paragraph still quoted its
if: conditions as always()-based even though a later paragraph in the
same entry already documents that the whole selftest job (including
these steps) was converted to !cancelled() in the same pass. A reader
copying the quoted condition strings would get the wrong syntax. Fixed
by updating the literal examples in place, per CodeRabbit's finding
(verified against the actual shipped batch-check.yml before fixing).

The other CodeRabbit comment in the same review (a dedicated regression
test for conda_avail's dual-path check) is a repeat of a suggestion
already declined with documented reasoning in this same entry -- no
action needed.

Held locally, not pushed yet: a CI run for a644c2a is in flight and
pushing now would cancel it.

Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

Co-authored-by: Claude <noreply@anthropic.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@CLAUDE.md`:
- Around line 608-612: Update the conda probe description near the `id:
conda_avail` workflow reference to explicitly call it a dual-path `Test-Path`
fallback, covering both `condabin\conda.bat` and `Scripts\conda.bat` with
short-circuiting. Avoid describing it as a single `Test-Path` operation.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 52df1604-7079-4cee-98f5-1ae4b59af06b

📥 Commits

Reviewing files that changed from the base of the PR and between a644c2a and 6ff101f.

📒 Files selected for processing (1)
  • CLAUDE.md
📜 Review details
⏰ Context from checks skipped due to timeout. (8)
  • GitHub Check: Batch syntax/run check (contract-uv-fail)
  • GitHub Check: Batch syntax/run check (cache)
  • GitHub Check: Batch syntax/run check (conda-full)
  • GitHub Check: Batch syntax/run check (real)
  • GitHub Check: Batch syntax/run check (contract-uv)
  • GitHub Check: Batch syntax/run check (uv-dl-fallback)
  • GitHub Check: Batch syntax/run check (uv)
  • GitHub Check: Batch syntax/run check (justme-test)
🧰 Additional context used
📓 Path-based instructions (1)
**/*.{bat,cmd,ps1,py,yml,yaml,json,md}

📄 CodeRabbit inference engine (CLAUDE.md)

Use ASCII-only text; avoid emojis, curly quotes, em dashes, and other non-ASCII characters because batch/CMD parsing can break.

Files:

  • CLAUDE.md
🔇 Additional comments (1)
CLAUDE.md (1)

613-631: LGTM!

Comment thread CLAUDE.md Outdated
CodeRabbit caught a real wording imprecision: the step performs two
separate Test-Path calls (condabin\conda.bat, then Scripts\conda.bat)
combined with -or, not a single Test-Path call checking two paths.
Verified against the actual step in batch-check.yml before fixing.

Held locally, not pushed yet: a CI run triggered by 6ff101f is in
flight and pushing now would cancel it.

Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

Co-authored-by: Claude <noreply@anthropic.com>
conda-full lane run 30226246284 showed test_arguments_forwarded_as_
single_arguments_string reporting "1|1" (timed out) for a trivial
write-a-file-and-exit script -- the 5000ms HP_INSTALLER_TIMEOUT_MS
window was too tight under real Windows CI-runner contention, the
same flake class already fixed once for HP_FAILFAST_PROBE_MS.
Widened to 30000ms (costs nothing in the normal case) and bumped the
outer subprocess wait accordingly.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS
@mixmansoundude

Copy link
Copy Markdown
Owner Author

Ensure CI isn’t skipping things unnecessarily.

mixmansoundude pushed a commit that referenced this pull request Jul 27, 2026
- Add a non-gating NDJSON row (diag.conda.available) for the relocated
  conda_avail step's already-observable Write-Host/output, which had no
  NDJSON coverage since it was introduced in PR #390. Purely additive --
  pass is always true, no if: condition touches it, consistent with this
  PR's own "zero wiring yet" scope. Skipped CodeRabbit's suggested
  artifact-path addition (tests/~test-results.ndjson to "Upload test
  logs"): that file is already captured by the dedicated "Upload CI
  NDJSON" step earlier in the same job, so no new path is needed.
- Include unknown-pass rows (rendered as [-] in the self-test summary
  list) in the totals line via a new UNKNOWN count, so a row that isn't
  a boolean pass/fail no longer silently vanishes from the totals while
  still appearing in the bullet list.
- publish_index.py: replace a positional .format() call with an
  f-string per Ruff UP030/UP032.

Registered diag.conda.available in docs/agent-ndjson.md per the AGENT
DIRECTIVE (registry entry + Key-facts explanatory note).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS
mixmansoundude added a commit that referenced this pull request Jul 27, 2026
* chore: repo-wide ASCII cleanup (Unicode glyphs to ASCII equivalents)

Replaces cosmetic Unicode characters (checkmark/cross/warning glyphs,
em dashes, bullets, middle dots, arrows) with meaning-preserving ASCII
in CI log/summary text and promo SVG assets, so a repo-wide ASCII
sweep reports clean, not just the files CLAUDE.md's own sanity sweep
currently checks.

Files: .github/workflows/batch-check.yml, .github/workflows/pr-automerge.yml,
tools/diag/publish_index.py, tools/run_prechecks.ps1, and 6 promo/*.svg
logo assets (title/comment text only, no visual change).

One real bug caught while verifying: replacing the em dash inside the
promo SVGs' <!-- ... --> header comments with "--" produced invalid
XML, since XML comments forbid "--" anywhere in their content, not
just at the delimiters. Fixed by using a single hyphen there instead;
verified all 6 SVGs still parse as valid XML afterward.

The 4 promo/*.png files are binary image data and were never actually
non-ASCII text -- they only matched the initial repo-wide grep because
raw pixel bytes happen to include bytes >0x7F, which is meaningless
for a binary format. Left untouched.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

* ci: move conda_avail to right after the real first-install step (unwired)

Step 1 of 2 (owner-authorized: "if confident then implement"). Moves
the existing, currently-unused conda_avail diagnostic step from right
after the empty-repo bootstrap (its old, premature position -- the
root cause of the item-7/PR-390 circular-skip bug) to right after
selfapps_envsmoke.ps1, the traced genuine first step that performs a
real run_setup.bat bootstrap under HP_FORCE_CONDA_ONLY=1.

Deliberately still unwired -- zero if: conditions reference it in this
commit. This mechanism has already produced two real bugs in quick
succession; landing the corrected position alone first, with nothing
depending on it, lets the next conda-full CI run prove `available`
correctly flips to 'true' before any gating logic returns.

Found and fixed a real YAML syntax error while validating locally
(actionlint/yamllint): the new step name contained a literal "if:"
inside unquoted text, which YAML parsed as a nested mapping key --
quoted the name to fix.

Also documents a wrinkle found mid-implementation: envsmoke itself was
one of the 9 "every lane" steps gated in the ORIGINAL design, but it's
now the producer of the signal, not a consumer, so it (and the other
8 steps in that category) must stay unconditional going forward -- only
the 27 already-enumerated real/conda-full-restricted steps are ever
candidates for the follow-up wiring commit.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

* ci: address CodeRabbit findings on PR #394

- Add a non-gating NDJSON row (diag.conda.available) for the relocated
  conda_avail step's already-observable Write-Host/output, which had no
  NDJSON coverage since it was introduced in PR #390. Purely additive --
  pass is always true, no if: condition touches it, consistent with this
  PR's own "zero wiring yet" scope. Skipped CodeRabbit's suggested
  artifact-path addition (tests/~test-results.ndjson to "Upload test
  logs"): that file is already captured by the dedicated "Upload CI
  NDJSON" step earlier in the same job, so no new path is needed.
- Include unknown-pass rows (rendered as [-] in the self-test summary
  list) in the totals line via a new UNKNOWN count, so a row that isn't
  a boolean pass/fail no longer silently vanishes from the totals while
  still appearing in the bullet list.
- publish_index.py: replace a positional .format() call with an
  f-string per Ruff UP030/UP032.

Registered diag.conda.available in docs/agent-ndjson.md per the AGENT
DIRECTIVE (registry entry + Key-facts explanatory note).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

---------

Co-authored-by: Claude <noreply@anthropic.com>
mixmansoundude pushed a commit that referenced this pull request Jul 27, 2026
Gates the conda-full half of 22 real/conda-full self-test steps plus 5
conda-full-only steps on steps.conda_avail.outputs.available == 'true'
(skip fast instead of each independently retrying a doomed sub-bootstrap).
Ships paired with a new "Enforce Miniconda availability" tripwire step
that unconditionally fails the job when that reads anything but 'true'
in the conda-full lane -- deliberately without distinguishing a genuine
Miniconda install failure from a bug in the gate mechanism itself, per
explicit owner direction to default to a loud failure either way. This
is what makes the gate safe to ship: shipping it alone would reintroduce
the exact PR #390 failure class (a wrong condition silently skips real
tests while the job stays green).

Owner-directed after a full risk/benefit assessment discussed in chat,
including exploring (and declining, with documented reasoning) an
additional CI-level retry mechanism on top of run_setup.bat's own
already-comprehensive Miniconda recovery (AllUsers->JustMe, REQ-022
retry, REQ-013 connectivity retry, download-URL fallback, bounded
installer timeout).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS
mixmansoundude added a commit that referenced this pull request Jul 28, 2026
…#397)

* ci: wire conda_avail gate to 27 conda-full self-tests + loud tripwire

Gates the conda-full half of 22 real/conda-full self-test steps plus 5
conda-full-only steps on steps.conda_avail.outputs.available == 'true'
(skip fast instead of each independently retrying a doomed sub-bootstrap).
Ships paired with a new "Enforce Miniconda availability" tripwire step
that unconditionally fails the job when that reads anything but 'true'
in the conda-full lane -- deliberately without distinguishing a genuine
Miniconda install failure from a bug in the gate mechanism itself, per
explicit owner direction to default to a loud failure either way. This
is what makes the gate safe to ship: shipping it alone would reintroduce
the exact PR #390 failure class (a wrong condition silently skips real
tests while the job stays green).

Owner-directed after a full risk/benefit assessment discussed in chat,
including exploring (and declining, with documented reasoning) an
additional CI-level retry mechanism on top of run_setup.bat's own
already-comprehensive Miniconda recovery (AllUsers->JustMe, REQ-022
retry, REQ-013 connectivity retry, download-URL fallback, bounded
installer timeout).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

* ci: fix CodeRabbit findings on PR #397 (every-lane wording, template-injection hardening)

- The conda_avail/conda_avail_gate steps' own if: already excludes the
  HP_CACHE_CORRUPTED=1 path, so "runs in every lane" was inaccurate --
  corrected to "every non-cache-corrupted lane" in both the workflow
  comment and CLAUDE.md's mirrored description.
- Route conda_avail's output through an env: mapping instead of
  interpolating it directly into the PowerShell script body, per a
  zizmor template-injection info-level finding. The value was never
  attacker-controlled (an enum string from our own prior Test-Path
  check), but the env: form is the established safe idiom and costs
  nothing to use for newly-authored code.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015xbWLPbiaKVsobB9FZy8kS

---------

Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants