Skip to content

ci: drop the Windows Defender exclusion step, it bought nothing - #350

Merged
getappz merged 1 commit into
masterfrom
ci/drop-defender-step
Jul 27, 2026
Merged

ci: drop the Windows Defender exclusion step, it bought nothing#350
getappz merged 1 commit into
masterfrom
ci/drop-defender-step

Conversation

@getappz

@getappz getappz commented Jul 27, 2026

Copy link
Copy Markdown
Owner

Removes the Windows Defender exclusion step added in #349. It was justified by a hypothesis, and measurement refutes it.

The measurement

Warm-to-warm on master, Windows leg — run 30245176121 (before #349) against a rerun of 30245841953 (after, with its own cache restored):

step before after Δ
rust-cache restore 30s 37s +7s
sccache setup 1s 7s +6s
Defender exclusions 3s +3s
cargo build --workspace 1m41s (removed) −101s
cargo test --workspace 3m12s 3m54s +42s
total 5m33s 4m53s −40s (−12%)
of which pure test execution 74.7s 72.9s −1.8s

Test execution — the thing Defender scanning would have slowed — moved 74.7s to 72.9s. That is noise, for a step that costs 3s to run.

The premise was wrong before the step was written: the ~90s test-execution figure I cited came from a PR run, while the baseline it was implicitly compared against was a master run at 74.7s. There was never an 90s-vs-20s gap on the branch being measured.

The comment left in place of the step records this, so the next person to look at the slow Windows leg doesn't retry the same idea blind.

What is kept, and why

Dropping the duplicate cargo build --workspace — kept. This is the entire measured win. Note it nets −40s, not the −101s the step's own duration suggests: the shared compilation moved into cargo test, which grew by 42s. Still a real 12%.

CARGO_PROFILE_DEV_DEBUG=line-tables-only — kept, though also unsupported by this data. Cache restore did not shrink (30s → 37s). Keeping it anyway is a judgment call rather than a measured one: reverting costs another full cold rebuild across all three OSes to chase a difference inside the noise band, and smaller artifacts still have value against cache size limits. If it should go too, it is a one-line revert — but worth batching with something else that already invalidates the cache.

Verification

Workflow YAML parsed and the resulting build step list checked. No Rust code changes in this PR.

Summary by CodeRabbit

  • Chores
    • Updated the Windows build workflow by removing ineffective Defender exclusion setup.
    • Removed an obsolete workflow security-scan suppression comment.
    • Documented the performance findings for Windows build runs.

Added on the theory that real-time scanning of build output and test temp
files was behind the slow Windows leg. Measured warm-to-warm on master
(run 30245176121 against a rerun of 30245841953), test execution went
74.7s to 72.9s -- inside the noise band -- for a step costing 3s.

The ~90s figure that motivated it came from a PR run, not the master
baseline it was compared against, so the premise was wrong before the
step was written. The comment left behind records the measurement so the
next person doesn't retry it blind.

The same measurement confirms the change that did pay: dropping the
duplicate cargo build took the Windows leg from 5m33s to 4m53s.
@coderabbitai

coderabbitai Bot commented Jul 27, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 2a78dd08-b60c-4b76-bbf4-31e731f040f7

📥 Commits

Reviewing files that changed from the base of the PR and between f58dff0 and b8b66fb.

📒 Files selected for processing (1)
  • .github/workflows/ci.yml

📝 Walkthrough

Walkthrough

The CI build workflow removes the Windows Defender exclusion attempt and its error handling, updates the related documentation, and removes an inline zizmor template-injection ignore comment.

Changes

CI workflow updates

Layer / File(s) Summary
Build job cleanup
.github/workflows/ci.yml
The Windows Defender exclusion step and its error handling were removed, the surrounding comment was updated, and the inline zizmor suppression was deleted. The job proceeds directly to cargo test.

Estimated code review effort: 2 (Simple) | ~5 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: removing the Windows Defender exclusion step from CI.
Description check ✅ Passed The PR explains the change, rationale, measurements, and verification, though it omits the template's Test plan and Notes for reviewers sections.
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 ci/drop-defender-step

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

@getappz
getappz merged commit f5b2275 into master Jul 27, 2026
18 checks passed
@getappz
getappz deleted the ci/drop-defender-step branch July 27, 2026 07:47
getappz added a commit that referenced this pull request Aug 11, 2026
…ge collisions (#456)

* git-shim/worktree residual polish: teardown messaging, branch-create accuracy, stranded-checkout recovery

- worktree deny message now distinguishes provisioning (claim) from
  teardown (check_merge/release/audit --prune) so an agent denied
  mid-teardown gets the exact cleanup action (vent #350)
- is_branch_create() classifies checkout -b/-B and switch -c/-C;
  canonical-checkout deny says 'create a new branch' instead of the
  misleading 'would detach HEAD' (vent #395)
- audit_orphans flags worktrees stranded on the default branch (intact
  gitdir) so worktree audit --prune clears the gh pr merge --delete-
  branch / post-merge-sync collision root cause (vents #351/#394/#423)
- AGENTFLARE_GIT_ALLOW_CANONICAL_MUTATE now also lifts the default-branch
  checkout/switch deny in the canonical checkout, giving stranded
  checkouts a sanctioned way back (vent #386 residual)
- allowlist classify.rs (already 1604L on master) in the LOC gate

Agentflare-Agent: 1
Agentflare-Branch: task/441
Agentflare-Item: 441

* fix(git-shim): close branch-create detection gaps, protect dirty stranded worktrees

CodeRabbit review on PR #456:
- is_branch_create only matched exact -b/-B/-c/-C, missing --orphan
  (checkout+switch), switch's --create/--force-create long forms, and
  attached short-option spellings (-bname). Those forms slipped past
  both would_detach_head and deny_canonical_detach_reason undetected,
  letting an agent create a branch in the canonical checkout via e.g.
  'git switch --orphan x' or 'git checkout -bx' with no deny at all.
- audit_orphans' new on-default-branch detection could hand a dirty,
  uncommitted stranded worktree to gc_orphans for deletion; the only
  other gc_orphans caller (cleanup_item_worktree) already refuses on
  a dirty status check first. Apply the same guard here.

Agentflare-Agent: claude-code_2-1-227_agent
Agentflare-Branch: task/441
Agentflare-Item: 441
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.

1 participant