Skip to content

Fix flaky cleanup and bottle tests - #24118

Merged
krehel merged 1 commit into
mainfrom
cleanup-lock-test
Sep 29, 2026
Merged

krehel merged 1 commit into
mainfrom
cleanup-lock-test

Conversation

@MikeMcQuaid

Copy link
Copy Markdown
Member
  • Keep the cleanup test lock alive and exercise garbage collection.
  • Use bottle URLs with known cache filenames to avoid network timeouts.
  • Reject HTTP header lookups in the checksum tests.

  • Have you followed our Contributing guidelines?
  • Have you checked for other open Pull Requests for the same change?
  • Have you explained what your changes do? Performance claims (e.g. "this is faster") must include brew benchmark results.
  • Have you explained why you'd like these changes included, not just what they do?
  • For bug fixes, have you given step-by-step brew commands to reproduce the bug?
  • Have you written new tests (excluding integration tests)? Here's an example.
  • Have you successfully run brew lgtm (style, typechecking and tests) locally?

  • I did not use AI/LLM to create this PR, or I disclosed the tool/model below and reviewed its output; I did not attribute commits to AI and will answer maintainer questions and review comments myself without AI/LLM.

Codex with GPT 6 Astra at Extra High effort, with local review and testing.


- Keep the cleanup test lock alive and exercise garbage collection.
- Use bottle URLs with known cache filenames to avoid network timeouts.
- Reject HTTP header lookups in the checksum tests.
Copilot AI lite review requested due to automatic review settings September 29, 2026 11:24

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot review overview

🟢 Approval recommended

No unresolved issues were identified.

Review effort: Lite
Findings: None

What changed in this PR

Fixes flaky cleanup and bottle tests by preserving lock lifetimes and avoiding network-dependent lookups.

Changes:

  • Keeps the cleanup lock open during garbage collection.
  • Uses deterministic bottle cache paths.
  • Prevents checksum tests from performing HTTP header lookups.
File Description
Library/​Homebrew/​test/​cleanup_spec.rb Stabilizes locked-file cleanup coverage.
Library/​Homebrew/​test/​bottle_spec.rb Makes bottle cache and checksum tests deterministic.

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

@krehel

krehel commented Sep 29, 2026

Copy link
Copy Markdown
Member

Thanks!

@krehel
krehel added this pull request to the merge queue Sep 29, 2026
Merged via the queue into main with commit 47b6582 Sep 29, 2026
53 checks passed
@krehel
krehel deleted the cleanup-lock-test branch September 29, 2026 14:30
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.

3 participants

⌂ 换网址