Skip to content

Commit

Permalink
Update docs to remove flake8, isort mentions and add ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
melissawm committed Oct 22, 2024
1 parent 4043d7f commit 5f5bcbc
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 15 deletions.
10 changes: 3 additions & 7 deletions docs/developers/contributing/dev_install.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,13 +88,9 @@ In order to make changes to `napari`, you will need to [fork](https://docs.githu
see [`black`'s documentation](https://black.readthedocs.io/en/stable/).

Code will also be linted to enforce the stylistic and logistical rules specified
in our [`flake8` configuration](https://github.com/napari/napari/blob/main/setup.cfg), which currently ignores
[E203](https://lintlyci.github.io/Flake8Rules/rules/E203.html),
[E501](https://lintlyci.github.io/Flake8Rules/rules/E501.html),
[W503](https://lintlyci.github.io/Flake8Rules/rules/W503.html) and
[C901](https://lintlyci.github.io/Flake8Rules/rules/C901.html). For information
on any specific flake8 error code, see the [Flake8
Rules](https://lintlyci.github.io/Flake8Rules/). You may also wish to refer to
in our [`ruff` configuration](https://github.com/napari/napari/blob/b9dc8dca1e1afa7567586e7ffa7a36cc7cd9fb6f/pyproject.toml#L219). For information
on any specific `ruff` error code, see the [Ruff
Rules](https://docs.astral.sh/ruff/rules/). You may also wish to refer to
the [PEP 8 style guide](https://peps.python.org/pep-0008/).

If you wish to tell the linter to ignore a specific line use the `# noqa`
Expand Down
2 changes: 1 addition & 1 deletion docs/developers/coredev/core_dev_guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ As a core member, you should be familiar with the following napari guides:
for docstring conventions.
- [`pre-commit`](https://pre-commit.com) hooks for autoformatting.
- [`black`](https://github.com/psf/black) autoformatting.
- [`flake8`](https://github.com/PyCQA/flake8) linting.
- [`ruff`](https://github.com/astral-sh/ruff) linting.

### Social resources

Expand Down
8 changes: 1 addition & 7 deletions docs/plugins/virtual_environment_docs/4-developer-tools.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Many are very helpful, but they do take a little time to learn. The more time yo

### Linting tools
These _check_ your code.
* [flake8](https://flake8.pycqa.org/) - checks various code style conventions, unused variables, line spacings, etc…
* [ruff](https://github.com/astral-sh/ruff) - checks various code style conventions, unused variables, line spacings, etc…
* [mypy](https://github.com/python/mypy)
- Static type checker: enforces proper usage of types.
- Super useful once you get the hang of it, but definitely an intermediate-advanced tool.
Expand All @@ -25,12 +25,6 @@ These _check_ your code.
These _auto-modify_ your code.
* [black](https://github.com/psf/black)
Forces code to follow specific style, indentations, etc...
* [autoflake](https://github.com/myint/autoflake)
Auto-fixes some flake8 failures.
* [isort](https://github.com/PyCQA/isort)
Auto-sorts and formats your imports.
* [setup-cfg-fmt](https://github.com/asottile/setup-cfg-fmt)
Sorts and enforces conventions in setup.cfg.

### Pre-commit tools
* [pre-commit](https://pre-commit.com/), runs all your checks each time you run git commit, preventing bad code from ever getting checked in.
Expand Down

0 comments on commit 5f5bcbc

Please sign in to comment.