-
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
Do not apply altsrc input values that are not set #1376
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
so that it doesn't extend the public surface area, instead focusing on being a bugfix _only_.
meatballhat
added
kind/bug
describes or fixes a bug
kind/feature
describes a code enhancement / feature request
area/v2
relates to / is being considered for v2
labels
Apr 26, 2022
Working on the codecov bit now 👍🏼 |
gesellix
added a commit
to gesellix/couchdb-prometheus-exporter
that referenced
this pull request
May 26, 2022
Other file formats like JSON or YAML would provide more type information, and unmarshalling would create correct types. Properties files aren't that useful, so we have to enforce some types by ourselves. We have to keep an eye on other types beside boolean, but this one seems sufficient for now. Relates to urfave/cli#1376, which made our previous workaround (see #81 and #83) fail due to a private function in the InputSourceContext interface.
gesellix
added a commit
to gesellix/couchdb-prometheus-exporter
that referenced
this pull request
May 26, 2022
Other file formats like JSON or YAML would provide more type information, and unmarshalling would create correct types. Properties files aren't that useful, so we have to enforce some types by ourselves. We have to keep an eye on other types beside boolean, but this one seems sufficient for now. Relates to urfave/cli#1376, which made our previous workaround (see #81 and #83) fail due to a private function in the InputSourceContext interface.
gesellix
added a commit
to gesellix/couchdb-prometheus-exporter
that referenced
this pull request
May 26, 2022
Other file formats like JSON or YAML would provide more type information, and unmarshalling would create correct types. Properties files aren't that useful, so we have to enforce some types by ourselves. We have to keep an eye on other types beside boolean, but this one seems sufficient for now. Relates to urfave/cli#1376, which made our previous workaround (see #81 and #83) fail due to a private function in the InputSourceContext interface.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area/v2
relates to / is being considered for v2
kind/bug
describes or fixes a bug
kind/feature
describes a code enhancement / feature request
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.
What type of PR is this?
What this PR does / why we need it:
This fixes the behavior of applied altsrc inputs so that they are only applied if the matching key exists in the input.
Which issue(s) this PR fixes:
Fixes #1373