-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Fix 2.1.0 regression #1014
Fix 2.1.0 regression #1014
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1014 +/- ##
========================================
Coverage ? 72.5%
========================================
Files ? 33
Lines ? 2495
Branches ? 0
========================================
Hits ? 1809
Misses ? 575
Partials ? 111
Continue to review full report at Codecov.
|
In case it'd be helpful to identify, the cause here is this diff - context := NewContext(a, set, nil)
+ context := NewContext(a, set, &Context{Context: ctx}) via https://github.com/urfave/cli/pull/975/files#diff-a66cc59eb6bfe62b7b3b69cd52b84747L227-R235 |
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.
LGTM
Motivation
Fixes #1015
Release Notes
Fixed a
Context
regression introduced in #1013Changes
When passing in
context.Background()
, initialize a*flagSet
value. This prevents the code from panicking whenflagSet
is accessed later.Testing
In addition to the automated tests, I stood up a testing package (here => coilysiren/testing-cli#1) with this new code. The testing package ran successfully with this new cli code.
Followup
After
v2.1.1
is released, I'll remove the commented out documentation lines. Also, this issue creates more justification for investigating #1006.Reviewer Guidelines
All our builds are broken until this is resolved 😅