-
Notifications
You must be signed in to change notification settings - Fork 4
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
Add python styleguides for use within Data Science and Statistics #59
base: main
Are you sure you want to change the base?
Conversation
added definition of linting
Update python.md
What do we think about Black? This can automatically PEP8ify your Python. |
# paths. | ||
ignore=CVS | ||
|
||
# Add files or directories matching the regex patterns to the blacklist. The |
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.
We should really use allow list & deny list.
# Specify a score threshold to be exceeded before program exits with error. | ||
fail-under=50 | ||
|
||
# Add files or directories to the blacklist. They should be base names, not |
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.
We should really use allow list & deny list.
# pygtk.require(). | ||
#init-hook= | ||
|
||
# Use multiple processes to speed up Pylint. Specifying 0 will auto-detect the |
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.
Black would be better than Pylint IMO - less to configure and purely PEP8. I get this whole file is for Pylint though 😄
# Pickle collected data for later comparisons. | ||
persistent=yes | ||
|
||
# When enabled, pylint would attempt to guess common misconfiguration and emit |
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.
Black needs no config 😄
**What is Linting?** | ||
A lint, or a linter, is a tool that analyzes your code to flag programming errors, bugs and stylistic errors. Simply put, a linter is a tool that scans your code with the goal of finding issues that could lead to bugs or inconsistencies with code health and style. | ||
|
||
* You should have as a minimum [pylint](https://pylint.org/#install) installed in order to quality check code before merging any Pull Requests. You can find install instructions on the linked homepage and further setup instructions on their [github page](https://github.com/PyCQA/pylint). Here is a [nice tutorial](http://pylint.pycqa.org/en/latest/tutorial.html) should its usage not be clear. |
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.
- Linting should be done in a Concourse pipeline. We should encourage local installation, but neither rely on it being installed locally or require it.
- Could we use Black over Pylint? Is there a specific need for Pylint?
Added styleguides for Python following the rise of Python usage within Data Science, Analysis and Insight. The content currently includes: