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

feat: warn on empty cache #9236

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

Merged
merged 4 commits into from
Oct 10, 2024
Merged

feat: warn on empty cache #9236

merged 4 commits into from
Oct 10, 2024

Conversation

NicholasLYang
Copy link
Contributor

Description

Warns if cache payload consists of just the log file and output globs are specified.

Testing Instructions

Turns out all of our test fixtures have empty outputs so we get a lot of these warnings in tests

Copy link

vercel bot commented Oct 8, 2024

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

Name Status Preview Comments Updated (UTC)
examples-nonmonorepo ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 10, 2024 2:34pm
8 Skipped Deployments
Name Status Preview Comments Updated (UTC)
examples-basic-web ⬜️ Ignored (Inspect) Visit Preview Oct 10, 2024 2:34pm
examples-designsystem-docs ⬜️ Ignored (Inspect) Visit Preview Oct 10, 2024 2:34pm
examples-gatsby-web ⬜️ Ignored (Inspect) Visit Preview Oct 10, 2024 2:34pm
examples-kitchensink-blog ⬜️ Ignored (Inspect) Visit Preview Oct 10, 2024 2:34pm
examples-native-web ⬜️ Ignored (Inspect) Visit Preview Oct 10, 2024 2:34pm
examples-svelte-web ⬜️ Ignored (Inspect) Visit Preview Oct 10, 2024 2:34pm
examples-tailwind-web ⬜️ Ignored (Inspect) Visit Preview Oct 10, 2024 2:34pm
examples-vite-web ⬜️ Ignored (Inspect) Visit Preview Oct 10, 2024 2:34pm

Copy link
Member

@tknickman tknickman left a comment

Choose a reason for hiding this comment

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

Looks great, thanks!

I think we should also skip the cache save in this case. But we can also address that in a follow up.

@tknickman tknickman merged commit dc705a2 into main Oct 10, 2024
40 checks passed
@tknickman tknickman deleted the nicholasyang/warn-on-empty-cache branch October 10, 2024 15:20
chris-olszewski added a commit that referenced this pull request Oct 17, 2024
### Description

I've noticed this integration test has been flakey lately:
-
https://github.com/vercel/turborepo/actions/runs/11387765428/job/31683165527
-
https://github.com/vercel/turborepo/actions/runs/11386983833/job/31680539914
-
https://github.com/vercel/turborepo/actions/runs/11356438462/job/31587646091

Partially reverts changes from #9236 for the cases that I've seen fail.
I don't remember this test being flakey before, so I'm changing it back.
I'm assuming we're now capturing [some
lines](https://github.com/vercel/turborepo/blob/ef2dc90030c6103393d42bdd5fb7f3584f1466a8/turborepo-tests/integration/tests/run-logging/log-order-stream.t#L47)
that aren't deterministic in ordering.

### Testing Instructions

Ran the test a few times and didn't get any failures. Hopefully CI is
green.
NicholasLYang added a commit that referenced this pull request Oct 21, 2024
### Description

In #9236 I added a check if the task output globs are empty. Turns out
we need to check if the output globs only has a single entry for the log
file.

Fixes #9291

### Testing Instructions

`basic_monorepo` has both a task that has globs and no outputs and a
task that has empty globs and no outputs. Note that we warn for one and
not the other.
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