-
Notifications
You must be signed in to change notification settings - Fork 441
fix: replace yamllint library install with exec call #876
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
importing yamllint directly into the cli is not an option due to license issues this maintains functionality while bringing us into compliance Signed-off-by: Nathan Weinberg <nweinber@redhat.com>
Would it be okay to install yamllint but not import it? If you keep |
@mrutkows would you know the answer to this? |
I think the unit tests are failing as when
We can't do the former method of inline YAML rules in the code due to the execing out - I'd like to have an explicit path to that file but not sure how to get an absolute path to the CLI root dir, would anyone know a way to do so or have an idea for another solution? |
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 from a revert PoV. Unit tests need to pass of course... Thanks @nathan-weinberg for such a quick response!
Resolves #870 once merged. |
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'm happy with it from a licensing PoV.
I have one implementation suggestion, though.
So can supply the inline string of the default config as a string on the command line. usage: yamllint [-h] [-] [-c CONFIG_FILE | -d CONFIG_DATA] [--list-files] [-f {parsable,standard,colored,github,auto}] [-s] [--no-warnings] [-v]
[FILE_OR_DIR ...] |
Signed-off-by: Nathan Weinberg <nweinber@redhat.com>
Previously was vice versa Signed-off-by: Nathan Weinberg <nweinber@redhat.com>
revert related changes to README.md Signed-off-by: Nathan Weinberg <nweinber@redhat.com>
Signed-off-by: Nathan Weinberg <nweinber@redhat.com>
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.
Approving this necessary reversion.
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.
Existing test cases are passing, and it's taking care of the licensing consideration. Should be good for now, I'm guessing we'll have follow ups for this later on.
Changes
Which issue is resolved by this Pull Request:
Resolves #870
Description of your changes:
yamllint
fromrequirements.txt
yamllint
to required binaries list inREADME.md
.yamllint
file with default rules to replace in-line code, changed CLI default fromyaml_rules.yaml
to.yamllint
to match (see https://yamllint.readthedocs.io/en/stable/configuration.html)ilab diff
click arg to align withilab generate
read_taxonomy_file
to exec out toyamllint
instead of doing the non-compliant library import methodSome test output (note I have
DEBUG
log level here):