-
Notifications
You must be signed in to change notification settings - Fork 358
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
Standardize code style using Black #1284
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1284 +/- ##
==========================================
+ Coverage 92.77% 95.11% +2.33%
==========================================
Files 34 34
Lines 7266 7266
==========================================
+ Hits 6741 6911 +170
+ Misses 525 355 -170
Continue to review full report at Codecov.
|
requirements-dev.txt
Outdated
@@ -18,6 +18,7 @@ pypandoc | |||
ipython | |||
|
|||
# Linter | |||
black==19.10b0; python_version >= "3.6" |
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.
FYI, this file is being shared with conda of the CI too, which has a slightly different syntax comparing to the regular PIP.
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.
Yep... I was hopeful conda/conda-build#1984 supported it, but I think it's for something different. :( I'll add it differently.
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.
Actually, I was trying to figure out yesterday where the other library requiring Python (Conda) 3.6+ is and couldn't find it; figured I'd support this similarly.
https://github.com/databricks/koalas/blob/master/.travis.yml#L69
maybe i think we have same discussed about using can you refer to this PR and this comment ? |
I saw previous discussions (#755 and #756), but I think I missed that part of the discussion on #761. I would be feel pretty against using Black just on diffs--rather than a consistent code style, you end up with an even worse mix between old and now. If there are certain formatting rules would like to tweak, Black supports that, as long as those options are applied consistently throughout. |
The problem is that, it overwrites the commit logs and difficult to track the changes. Also, I would like to keep it as an option, not a hard requirement because some people prefers a different style. After all, we still run multiple linters so it's fine as long as it follows. PEP 8 |
@@ -0,0 +1,6 @@ | |||
repos: |
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.
Hm, I was thinking about using .git/hooks/pre-commit
right away rather then using a dependency for now.
Okay, let me take a look and fix it if it's really worthwhile. I will port some changes here and make the commit co-authored. |
Let me make #1301 co-authored. thanks @deepyaman! |
Close #755
TODO: