-
Notifications
You must be signed in to change notification settings - Fork 2k
fix: respect output mode 'none' even when caching is disabled #9670
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
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One extremely minor suggestion, but otherwise LFG!
if self.caching_disabled || self.run_cache.writes_disabled { | ||
log_writer.with_writer(writer); | ||
return Ok(log_writer); | ||
if !self.caching_disabled && !self.run_cache.writes_disabled { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Translating this for myself: "if a task has "cache": true
and is run at least one cache it can write to"
This is changed from: "if task has "cache": false
or cannot write to disk"
|
||
// Returning the buffer's length so callers don't think this is a failure to | ||
// create the buffer | ||
Ok(buf.len()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice catch! This was dead code before so we were never hitting the bad return of Ok(0)
, thanks for fixing up my mistake.
Co-authored-by: Chris Olszewski <chris.olszewski@vercel.com>
Description
This is a fresh PR for #7900, which sat too long and got stale. I accidentally closed the PR with no commits after force-pushing so I'm opening this for simplicity's sake.
@aholland deserves all credit here for finding this issue and proposing a fix.
Testing Instructions