[GRASS-git] [OSGeo/grass] 870343: style: Fix if-else-block-instead-of-if-exp (SIM108...
Edouard Choinière
noreply at github.com
Sun Oct 20 14:07:17 PDT 2024
Branch: refs/heads/main
Home: https://github.com/OSGeo/grass
Commit: 870343fe17389f3d40d0c6fa81a906d07805ac65
https://github.com/OSGeo/grass/commit/870343fe17389f3d40d0c6fa81a906d07805ac65
Author: Edouard Choinière <27212526+echoix at users.noreply.github.com>
Date: 2024-10-20 (Sun, 20 Oct 2024)
Changed paths:
M doc/python/raster_example_ctypes.py
M doc/python/vector_example_ctypes.py
M lib/init/grass.py
M man/build_html.py
M temporal/t.info/t.info.py
M temporal/t.list/t.list.py
M temporal/t.rast.accdetect/t.rast.accdetect.py
M temporal/t.rast.accumulate/t.rast.accumulate.py
M temporal/t.rast.aggregate/t.rast.aggregate.py
M temporal/t.rast.to.rast3/t.rast.to.rast3.py
M temporal/t.rast.what/t.rast.what.py
M temporal/t.rename/t.rename.py
M temporal/t.topology/t.topology.py
M temporal/t.unregister/t.unregister.py
M temporal/t.vect.observe.strds/t.vect.observe.strds.py
M temporal/t.vect.what.strds/t.vect.what.strds.py
M utils/g.html2man/ggroff.py
M utils/mkrest.py
M utils/ppmrotate.py
M utils/update_version.py
Log Message:
-----------
style: Fix if-else-block-instead-of-if-exp (SIM108) (part 1) (#4561)
Ruff rule: https://docs.astral.sh/ruff/rules/if-else-block-instead-of-if-exp
Since the amount of changes for SIM108 are quite large, (more than 330), I've decided to split the fixes in more than 1 PR. I kept `scripts/*`, `python/*` and `gui/*` in other PRs.
To avoid conflicts, I didn't commit the modified `pyproject.toml`, nor extra typing annotations that I used to help guiding and validating these fixes.
* style: Fix if-else-block-instead-of-if-exp (SIM108) in utils/
* style: Fix if-else-block-instead-of-if-exp (SIM108) in lib/init/grass.py
* style: Fix if-else-block-instead-of-if-exp (SIM108) in doc/
* style: Fix if-else-block-instead-of-if-exp (SIM108) in man/build_html.py
* style: Fix if-else-block-instead-of-if-exp (SIM108) in temporal/
* style: Manual fixes of if-else-block-instead-of-if-exp (SIM108) in temporal/
To unsubscribe from these emails, change your notification settings at https://github.com/OSGeo/grass/settings/notifications
More information about the grass-commit
mailing list