Skip to content

Commit

Permalink
Merge pull request #8 from RolnickLab/fix-docformatter
Browse files Browse the repository at this point in the history
Fix docformatter
  • Loading branch information
f-PLT authored Sep 23, 2024
2 parents 3deb391 + efa8041 commit 24586f8
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 9 deletions.
1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ repos:
hooks:
- id: docformatter
args: [ --in-place ]
additional_dependencies: [tomli]

- repo: https://github.com/PyCQA/flake8
rev: 7.0.0
Expand Down
3 changes: 2 additions & 1 deletion CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
[Unreleased](https://github.com/RolnickLab/geospatial-tools/tree/main) (latest)
-------------------------------------------------------------------------------------

[//]: # (New changes here in list form)
- Fix `docformatter` with missing extra dependency for use with `pyproject.toml`


[0.1.1](https://github.com/RolnickLab/geospatial-tools/tree/0.1.1) (2024-09-20)
-------------------------------------------------------------------------------------
Expand Down
3 changes: 2 additions & 1 deletion poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ pystac-client = "^0.7.7"
planetary-computer = "^1.0.0"
rioxarray = "^0.15.5"
pyogrio = "^0.8.0"
docformatter = {extras = ["toml"], version = "^1.7.5"}
dask-geopandas = "^0.4.1"
pyarrow = "^17"
numpy = "^2.1.1"
Expand All @@ -40,10 +39,10 @@ flynt = "^1.0.1"
flake8 = "^7.0.0"
pre-commit = "^3.7.0"
flake8-pyproject = "^1.2.3"
docformatter = {extras = ["toml"], version = "^1.7.5"}
docformatter = {extras = ["tomli"], version = "^1.7.5"}
nbval = "^0.11.0"

black = "^24.8.0"

[tool.poetry.group.lab.dependencies]
jupyterlab = "^4.0.10"
notebook = "^7.0.6"
Expand Down
8 changes: 4 additions & 4 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ allowlist_externals = poetry
commands_pre =
poetry install

file_and_folder_list_all = geospatial_tools/ tests/ scripts/
file_and_folder_list_module = geospatial_tools/ scripts/
file_and_folder_list_all = {toxinidir}/geospatial_tools/ {toxinidir}/tests/ {toxinidir}/scripts/
file_and_folder_list_module = {toxinidir}/geospatial_tools/ {toxinidir}/scripts/

[testenv:pylint]
commands =
Expand All @@ -25,14 +25,14 @@ commands =

[testenv:docformatter]
commands =
poetry run docformatter {[testenv]file_and_folder_list_all}
poetry run docformatter --config {toxinidir}/pyproject.toml {[testenv]file_and_folder_list_all}

[testenv:fix]
commands =
poetry run black {[testenv]file_and_folder_list_all}
poetry run isort {[testenv]file_and_folder_list_all}
poetry run flynt {[testenv]file_and_folder_list_all}
poetry run docformatter --in-place {[testenv]file_and_folder_list_all}
poetry run docformatter --in-place --config {toxinidir}/pyproject.toml {[testenv]file_and_folder_list_all}

[testenv:precommit]
commands =
Expand Down

0 comments on commit 24586f8

Please sign in to comment.