Skip to content

Update developer toolset instructions in CONTRIBUTING.md #7762

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

Cjkjvfnby
Copy link
Contributor

Replace/remove instructions on individual tools usage with pre-commit.
Instruction with flake8 is a bit misleading since the project uses flake8 plugins that should be installed to get the same linting as done by CI on each PR.

Also, add a few line breaks. It doe not affect rendered page and fits into the screen in the editor.

  • Add an algorithm?
  • Fix a bug or typo in an existing algorithm?
  • Documentation change?

Checklist:

  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized.
  • I know that pull requests will not be merged if they fail the automated tests.
  • This PR only changes one algorithm file. To ease review, please open separate PRs for separate algorithms.
  • All new Python files are placed inside an existing directory.
  • All filenames are in all lowercase characters with no spaces or dashes.
  • All functions and variable names follow Python naming conventions.
  • All function parameters and return values are annotated with Python type hints.
  • All functions have doctests that pass the automated testing.
  • All new algorithms have a URL in its comments that points to Wikipedia or other similar explanation.
  • If this pull request resolves one or more open issues then the commit message contains Fixes: #{$ISSUE_NO}.

@algorithms-keeper algorithms-keeper bot added documentation This PR modified documentation files awaiting reviews This PR is ready to be reviewed labels Oct 27, 2022
@algorithms-keeper algorithms-keeper bot mentioned this pull request Oct 27, 2022
14 tasks
@algorithms-keeper algorithms-keeper bot added awaiting changes A maintainer has requested changes to this PR and removed awaiting reviews This PR is ready to be reviewed labels Oct 29, 2022
@cclauss cclauss added ON HOLD: Final hours of Hacktoberfest We will review this PR after Hacktoberfest has ended and removed ON HOLD: Final hours of Hacktoberfest We will review this PR after Hacktoberfest has ended labels Oct 29, 2022
@Cjkjvfnby Cjkjvfnby force-pushed the remove-flake8-mention-from-CONTRIBUTING branch from 1a86be3 to 1e07427 Compare November 5, 2022 22:25
@algorithms-keeper algorithms-keeper bot added awaiting reviews This PR is ready to be reviewed and removed awaiting changes A maintainer has requested changes to this PR labels Nov 5, 2022
@Cjkjvfnby Cjkjvfnby requested a review from cclauss March 13, 2023 22:54
CONTRIBUTING.md Outdated
Comment on lines 84 to 90
- Please consider running [__psf/black__](https://github.com/python/black) on your Python file(s) before submitting your pull request. This is not yet a requirement but it does make your code more readable and automatically aligns it with much of [PEP 8](https://www.python.org/dev/peps/pep-0008/). There are other code formatters (autopep8, yapf) but the __black__ formatter is now hosted by the Python Software Foundation. To use it,

```bash
python3 -m pip install black # only required the first time
black .
```

Copy link
Contributor

Choose a reason for hiding this comment

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

In my opinion, this part isn't necessary because when you create the pr the pre-commit bot automatically formats it because it's in the pre-commit

@cclauss
Copy link
Member

cclauss commented Mar 17, 2023

I do not see the value of these changes.
Some contributors will install pre-commit but the majority will not so…

  • Black corrections will be made automatically so let’s not require it to be installed.
  • The same will be true of Ruff fixes in the future.
  • it is OK to discuss mypy as is currently done because it does not ”fix” code so having it installed locally might be helpful to some contributors.
  • Command line tools like Black, mypy, and ruff should be installed with pipx, not pip.

@Cjkjvfnby Cjkjvfnby closed this Mar 17, 2023
@Cjkjvfnby Cjkjvfnby deleted the remove-flake8-mention-from-CONTRIBUTING branch March 17, 2023 23:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting reviews This PR is ready to be reviewed documentation This PR modified documentation files
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants