Skip to content

Conversation

@connorjclark
Copy link
Collaborator

fixes #14361

@connorjclark connorjclark requested a review from a team as a code owner September 7, 2022 20:48
@connorjclark connorjclark requested review from brendankenny and removed request for a team September 7, 2022 20:48
@brendankenny
Copy link
Contributor

I feel like there's a super-ancient TODO about this that can maybe finally be deleted, but maybe it was already deleted...

if (value === undefined) return;

if (typeof value !== 'string' || !fs.existsSync(path.dirname(value))) {
if (typeof value !== 'string' || !value || !fs.existsSync(path.dirname(value))) {
Copy link
Contributor

Choose a reason for hiding this comment

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

In what situation will value === undefined.

If it's the case where --output-path is provided without any value, could we do a different error message for that?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

In what situation will value === undefined.

when not provided. coerce is still called when param is not specified (or at least, it is for the "flags in a json path" case).

If it's the case where --output-path is provided without any value, could we do a different error message for that?

I think the current error is sufficient.

@brendankenny
Copy link
Contributor

I feel like there's a super-ancient TODO about this that can maybe finally be deleted, but maybe it was already deleted...

oh, ha, still no:

// TODO: make this mkdir to the filePath.

humorously we'll create the path for -G in saveArtifacts, but still not for a path for just saving the LHR.

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.

Improve error response time

3 participants