Skip to content

fix: Align dry run cache status with normal run by checking caching guards#12448

Merged
anthonyshew merged 1 commit intomainfrom
shew/investigate-9044
Mar 26, 2026
Merged

fix: Align dry run cache status with normal run by checking caching guards#12448
anthonyshew merged 1 commit intomainfrom
shew/investigate-9044

Conversation

@anthonyshew
Copy link
Contributor

Summary

  • TaskCache::exists() (used by --dry) was missing the caching_disabled and reads_disabled guard checks that restore_outputs() (used by normal runs) performs. This caused --dry=json to report incorrect cache status when cache: false was set on a task or when cache reads were globally disabled.
  • Adds two integration tests: one verifying dry run reports HIT after a real run populates the cache, and one verifying dry run reports MISS when cache: false is configured.

Closes #9044

…uards

TaskCache::exists() (used by --dry) was missing the caching_disabled
and reads_disabled guard checks that restore_outputs() (used by normal
runs) performs. This caused --dry=json to report incorrect cache status
when cache:false was set or reads were disabled.

Closes #9044
@anthonyshew anthonyshew requested a review from a team as a code owner March 26, 2026 06:25
@anthonyshew anthonyshew requested review from tknickman and removed request for a team March 26, 2026 06:25
@vercel
Copy link
Contributor

vercel bot commented Mar 26, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
examples-basic-web Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am
examples-designsystem-docs Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am
examples-gatsby-web Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am
examples-kitchensink-blog Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am
examples-nonmonorepo Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am
examples-svelte-web Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am
examples-tailwind-web Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am
examples-vite-web Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am
turbo-site Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am
turborepo-agents Ready Ready Preview, Comment, Open in v0 Mar 26, 2026 6:26am

@anthonyshew anthonyshew enabled auto-merge (squash) March 26, 2026 06:27
@anthonyshew anthonyshew merged commit 48aa171 into main Mar 26, 2026
58 checks passed
@anthonyshew anthonyshew deleted the shew/investigate-9044 branch March 26, 2026 06:35
github-actions bot added a commit that referenced this pull request Mar 26, 2026
## Release v2.8.21-canary.11

Versioned docs: https://v2-8-21-canary-11.turborepo.dev

### Changes

- release(turborepo): 2.8.21-canary.10 (#12446) (`014111c`)
- fix: Align dry run cache status with normal run by checking caching
guards (#12448) (`48aa171`)

Co-authored-by: Turbobot <[email protected]>
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.

turbo run --dry=json says cache.local=false yet when I run the task, it says cache hit

1 participant