Skip to content

Commit

Permalink
[py] moved isort, black and docformatter settings from `tox.ini…
Browse files Browse the repository at this point in the history
…` file to `pyproject.toml` (#14671)

* moved isort,black and docformatter settings to pyproject.toml

* moved isort, black and docformatter settings to pyproject.toml

* removed redundant pytest settings from setup.cfg
  • Loading branch information
sandeepsuryaprasad authored Oct 29, 2024
1 parent e9e684d commit 8e95ea9
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 16 deletions.
16 changes: 16 additions & 0 deletions py/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,19 @@ ignore_missing_imports = true
[[tool.mypy._winreg]]
# suppress error messages about imports that cannot be resolved.
ignore_missing_imports = true

[tool.isort]
# isort is a common python tool for keeping imports nicely formatted.
# Automatically keep imports alphabetically sorted, on single lines in
# PEP recommended sections (https://peps.python.org/pep-0008/#imports)
# files or individual lines can be ignored via `# isort:skip|# isort:skip_file`.
profile = "black"
py_version=38
force_single_line = true

[tool.black]
line-length = 120
target-version = ['py38']

[tool.docformatter]
recursive = true
5 changes: 0 additions & 5 deletions py/setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,3 @@ exclude = .tox,docs/source/conf.py,*venv
extend-ignore = E501, E203
# This does nothing for now as E501 is ignored.
max-line-length = 120

[tool:pytest]
addopts = -ra
python_files = test_*.py *_tests.py
testpaths = test
11 changes: 0 additions & 11 deletions py/tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,6 @@ deps =
trio-typing==0.7.0
commands = mypy --install-types {posargs}


[isort]
; isort is a common python tool for keeping imports nicely formatted.
; Automatically keep imports alphabetically sorted, on single lines in
; PEP recommended sections (https://peps.python.org/pep-0008/#imports)
; files or individual lines can be ignored via `# isort:skip|# isort:skip_file`.
profile = black
py_version=38
force_single_line = True


[testenv:linting-ci]
; checks linting for CI with stricter exiting when failing.
skip_install = true
Expand Down

0 comments on commit 8e95ea9

Please sign in to comment.