Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
feat:
--100
#332feat:
--100
#332Changes from 2 commits
66cd626
3aecef0
b96dcda
279276e
1dc1063
79bc20c
244af62
90505ec
c4286d1
cb7c7ed
08dff42
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
this code doesn't seem to be executed. I haven't worked with yargs middleware before but it seems like a good approach here? Do you know why the code is not executed?
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.
This seems like a reasonable approach to me, and seems like it should work, perhaps:
I wouldn't expect the argument key itself to be coerced into an integer.
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.
my problem here is that the middleware is not applied at all. I think I'm missing something obvious. Any idea what it could be?
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.
I tested locally, it seems like this is a bug that I fixed in yargs@17, at least it works as expected with yargs@17 ...
Unfortunately, I think we might want to hold off on dropping Node 10 until I can drop Node 10 on the libraries I manage at Google.
We can implement a less elegant version here:
https://github.com/bcoe/c8/blob/main/lib/commands/report.js#L29
Which I believe should work in the appropriate contexts (we'll want to confirm it works for the
check-coverage
command).Let's add a
// TODO: comment
to switch to themiddleware
approach as soon as we can drop Node 10?