Skip to content

CI: isort ci #24746

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

Merged
merged 3 commits into from
Jan 14, 2019
Merged

CI: isort ci #24746

merged 3 commits into from
Jan 14, 2019

Conversation

alimcmaster1
Copy link
Member

  • passes git diff upstream/master -u -- "*.py" | flake8 --diff

asv_bench and doc dir where added to the isort skip section. We should actually check this directory in CI.

Checking doc dir is more effort that its worth ( barely any .py files ) so let's just leave this.

@codecov
Copy link

codecov bot commented Jan 12, 2019

Codecov Report

Merging #24746 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master   #24746   +/-   ##
=======================================
  Coverage   92.38%   92.38%           
=======================================
  Files         166      166           
  Lines       52358    52358           
=======================================
  Hits        48373    48373           
  Misses       3985     3985
Flag Coverage Δ
#multiple 90.81% <ø> (ø) ⬆️
#single 43.07% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 33f91d8...8d47066. Read the comment docs.

@codecov
Copy link

codecov bot commented Jan 12, 2019

Codecov Report

Merging #24746 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master   #24746   +/-   ##
=======================================
  Coverage   92.38%   92.38%           
=======================================
  Files         166      166           
  Lines       52363    52363           
=======================================
  Hits        48376    48376           
  Misses       3987     3987
Flag Coverage Δ
#multiple 90.81% <ø> (ø) ⬆️
#single 42.91% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6c84005...fa214cd. Read the comment docs.

@gfyoung gfyoung added CI Continuous Integration Code Style Code style, linting, code_checks labels Jan 13, 2019
Copy link
Member

@gfyoung gfyoung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gfyoung gfyoung added the Clean label Jan 13, 2019
@datapythonista
Copy link
Member

I understand the point of the PR, and this makes things more consistent, but I'm not a big fan of what we did with isort. So making the list of excludes even longer, seems the opposite direction we should take.

Not a problem with getting this merged, but would be nice to see a solution of a very strict and complex and not-human friendly validation of half of the code base, and no validation in the rest.

@datapythonista
Copy link
Member

Sorry, just saw that almost all the code has been isorted, didn't see that before. I guess this makes more sense then.

@alimcmaster1
Copy link
Member Author

alimcmaster1 commented Jan 13, 2019

hey thanks for the comments @datapythonista , how come you are not a fan of isort out of interest? - In my mind we previously had an undocumented set of rules for what import order should look like ( by dependency structure ) - so now we don't need to battle on PRs about what that order should be, I just run one command and don't have to worry/often IDE's like to change the import order too ( "optimize imports" in pycharm for example ).

I will follow up after this PR to isort the asv_bench directory.

@datapythonista
Copy link
Member

afaik none of the pandas devs is able to sort the imports properly unless using isort. I'm happy we respect pep8 and we have the imports sorted by stdlib, third-party and pandas. But the rest doesn't add any value, but extra steps and CI problems even for files with few imports.

@jreback
Copy link
Contributor

jreback commented Jan 13, 2019

using isort is much better than the alternative - random changes due to import ordering and re-ordering

@jreback
Copy link
Contributor

jreback commented Jan 13, 2019

can you merge master

@jreback jreback added this to the 0.24.0 milestone Jan 14, 2019
@jreback jreback merged commit 453fa85 into pandas-dev:master Jan 14, 2019
@jreback
Copy link
Contributor

jreback commented Jan 14, 2019

thanks @alimcmaster1

@alimcmaster1 alimcmaster1 deleted the isort-ci branch February 17, 2019 18:41
Pingviinituutti pushed a commit to Pingviinituutti/pandas that referenced this pull request Feb 28, 2019
Pingviinituutti pushed a commit to Pingviinituutti/pandas that referenced this pull request Feb 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous Integration Clean Code Style Code style, linting, code_checks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants