这是indexloc提供的服务,不要输入任何密码
Skip to content

fix(cache): avoid warning if TURBO_FORCE, TURBO_REMOTE_ONLY, and TURBO_CACHE #9704

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

chris-olszewski
Copy link
Member

Description

Previously we would erroneously warn users that TURBO_REMOTE_ONLY was being deprecated even if the correct TURBO_CACHE was also present. This happened because we have TURBO_FORCE erase caching behavior and this was happening before we checked if TURBO_REMOTE_ONLY had a matching TURBO_CACHE declaration. The fix is just doing that check before doing the force override.

Testing Instructions

Before

[0 olszewski@chriss-mbp] /Users/olszewski/code/vercel/turborepo $ TURBO_FORCE=1 TURBO_REMOTE_ONLY=1 TURBO_CACHE=remote:rw turbo_dev @turbo/t
ypes#build > /dev/null                                                                                                                      
 WARNING  No locally installed `turbo` found. Using version: 2.3.4-canary.6.                                                                
turbo 2.3.4-canary.6                                                                                                                        
                                                                                                                                            
 WARNING  TURBO_REMOTE_ONLY is deprecated and will be removed in a future major version. Use TURBO_CACHE=remote:rw

After:

[0 olszewski@chriss-mbp] /Users/olszewski/code/vercel/turborepo $ TURBO_FORCE=1 TURBO_REMOTE_ONLY=1 TURBO_CACHE=remote:rw turbo_dev @turbo/types#build > /dev/null
 WARNING  No locally installed `turbo` found. Using version: 2.3.4-canary.7.
turbo 2.3.4-canary.7

Copy link

vercel bot commented Jan 14, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
examples-basic-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 14, 2025 5:47pm
examples-designsystem-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 14, 2025 5:47pm
examples-gatsby-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 14, 2025 5:47pm
examples-kitchensink-blog ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 14, 2025 5:47pm
examples-native-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 14, 2025 5:47pm
examples-nonmonorepo ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 14, 2025 5:47pm
examples-svelte-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 14, 2025 5:47pm
examples-tailwind-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 14, 2025 5:47pm
examples-vite-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 14, 2025 5:47pm

@chris-olszewski chris-olszewski marked this pull request as ready for review January 14, 2025 17:47
@chris-olszewski chris-olszewski requested a review from a team as a code owner January 14, 2025 17:47
@chris-olszewski chris-olszewski merged commit 574ffa3 into main Jan 14, 2025
36 checks passed
@chris-olszewski chris-olszewski deleted the chrisolszewski/turbo-4254-rebuilding-without-cache-on-vercel-gives-the branch January 14, 2025 19:16
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