-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
BLD: Use Azure pipelines for linting #22844
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
Comments
I think we'll still need something similar to what's currently in I agree we should do something to make seeing lint failures easier for users. I'm not sure whether this needs to be done on azure or not. I haven't played with more complex pipelines or reporting, beyond the basic "here's a file of junit XML results". |
I was having a look, and I think for the ones that are a single command ( If I'm not wrong, the only other case that we've got are loops. I guess it's possible to have the whole loop as the script, but that wouldn't show directly which file failed (it'd probably be an improvement, even if to know the exact file we need to check the log). But I think it'd be even better, if azure provides a way to create a separate item for the values of the loop. Not sure if that's doable or how complex would the configuration. This is a case:
|
@datapythonista we have a model for highlighting issues in the log and in the summary view that also flows back to checks. You can echo out And that will get a treatment on the summary view that will include a link to the sourcefile and line number where the issues are found. For more details see https://github.com/Microsoft/vsts-tasks/blob/master/docs/authoring/commands.md. |
Thanks for the info @chrisrpatterson. That would be really nice to have. But I don't see how can I get this with flake8, which is generating the messages. The output we've got from the command is something like this:
Is there a "standards" way in Azure to change the format? We could do a script that changes from one format to another, and call @zooba suggested to start the lines with |
ok, in a first check to flake8 parameters I didn't see the format could be specified, but I double checked, and everything makes sense now: Will give it a try. |
Made some progress on this, and managed to make flake8 generate the correct output: https://dev.azure.com/pandas-dev/pandas/_build/results?buildId=437&view=logs It really improves the clarity of the errors (and even much more compared to our current solution, in the travis log). But still some issues:
We probably don't want to change the |
We have been having some discussions about other ways to make this sort of parsing a bit more generic but nothing has come to us yet. However, similar to test results there are probably a relatively small number of regex based formats we could build in support for recognizing. The other option might be to have a generic regex you could specify as part of the job or even the step that would be used for parsing out issues. |
FYI @pandas-dev/pandas-core : the reason why we can't view the pipeline dashboard for Travis is because we don't have the Travis GitHub app enabled on this repository. Unfortunately, there is no way to migrate from |
At the moment we have the script
ci/lint.sh
for validating PEP-8 and other linting. The script has several validations in the form of:If I'm not wrong, moving all those to the azure-pipelines configuration would have two advantages.
First, the code would be simpler, as all the bash stuff would be automatically managed, and we'ld simply have:
Second is that when one of those fails, it'll be faster to see which is the reason for the fail in the azure pipeline dashboard, instead of having to go into the details of the travis log.
Does this make sense? @jreback @TomAugspurger @chrisrpatterson @jeremyepling
The text was updated successfully, but these errors were encountered: