Upgrade click

Since `click` v8.2, a `Group` invoked without a subcommand
exits with status code 2 ("usage error") instead of 0.
This commit is contained in:
Alexander Hess 2026-11-25 12:35:01 +01:00
commit c310c335ff
Signed by: alexander
GPG key ID: B46EDB4DFC26805D
3 changed files with 9 additions and 12 deletions

15
poetry.lock generated
View file

@ -682,19 +682,16 @@ files = [
[[package]] [[package]]
name = "click" name = "click"
version = "8.1.8" version = "8.5.1"
description = "Composable command line interface toolkit" description = "Composable command line interface toolkit"
optional = false optional = false
python-versions = ">=3.7" python-versions = ">=3.10"
groups = ["main", "dev"] groups = ["main", "dev"]
files = [ files = [
{file = "click-8.1.8-py3-none-any.whl", hash = "sha256:63c132bbbed01578a06712a2d1f497bb62d9c1c0d329b7903a866228027263b2"}, {file = "click-8.5.1-py3-none-any.whl", hash = "sha256:8bb5376d2006950386f8c6427613334a2acadc5f559cb80e638d00b4df957e37"},
{file = "click-8.1.8.tar.gz", hash = "sha256:ed53c9d8990d83c2a27deae68e4ee337473f6330c040a31d4225c9574d16096a"}, {file = "click-8.5.1.tar.gz", hash = "sha256:9bbfada76703fd1d784b83eea012e3e8c6a001a876543ef104fa56aaaeb072b4"},
] ]
[package.dependencies]
colorama = {version = "*", markers = "platform_system == \"Windows\""}
[[package]] [[package]]
name = "colorama" name = "colorama"
version = "0.4.6" version = "0.4.6"
@ -706,7 +703,7 @@ files = [
{file = "colorama-0.4.6-py2.py3-none-any.whl", hash = "sha256:4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6"}, {file = "colorama-0.4.6-py2.py3-none-any.whl", hash = "sha256:4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6"},
{file = "colorama-0.4.6.tar.gz", hash = "sha256:08695f5cb7ed6e0531a20572697297273c47b8cae5a63ffc6d6ed5c201be6e44"}, {file = "colorama-0.4.6.tar.gz", hash = "sha256:08695f5cb7ed6e0531a20572697297273c47b8cae5a63ffc6d6ed5c201be6e44"},
] ]
markers = {main = "extra == \"research\" and sys_platform == \"win32\" or platform_system == \"Windows\"", dev = "platform_system == \"Windows\" or sys_platform == \"win32\""} markers = {main = "sys_platform == \"win32\" and extra == \"research\"", dev = "sys_platform == \"win32\" or platform_system == \"Windows\""}
[[package]] [[package]]
name = "colorlog" name = "colorlog"
@ -5050,4 +5047,4 @@ research = ["jupyterlab", "numpy", "pytz"]
[metadata] [metadata]
lock-version = "2.1" lock-version = "2.1"
python-versions = ">=3.13,<4.0" python-versions = ">=3.13,<4.0"
content-hash = "1b35da02710abc0388cd84fab3211add0f9efdcf1022d2fe60d54229148212d7" content-hash = "0b46413f07dbf5aa69a50176d15d46ae8720a11c1e49c2abd9921800c1c18399"

View file

@ -31,7 +31,7 @@ requires-python = ">=3.13,<4.0"
dependencies = [ dependencies = [
"Shapely>=1.7.1,<2.1", "Shapely>=1.7.1,<2.1",
"alembic>=1.4.2", "alembic>=1.4.2",
"click>=7.1.2,<8.2", "click>=7.1.2",
"folium>=0.12.1,<0.19", "folium>=0.12.1,<0.19",
"geopy>=2.1.0,<3", "geopy>=2.1.0,<3",
"googlemaps>=4.4.2,<5", "googlemaps>=4.4.2,<5",

View file

@ -65,10 +65,10 @@ class TestCLIWithoutCommand:
@pytest.mark.no_cover @pytest.mark.no_cover
def test_no_options(self, cli): def test_no_options(self, cli):
"""Exit with 0 status code and no output if run without options.""" """Exit with 2 status code (usage error) if run without options."""
result = cli.invoke(main.entry_point) result = cli.invoke(main.entry_point)
assert result.exit_code == 0 assert result.exit_code == 2
# The following test cases validate the --version / -V option. # The following test cases validate the --version / -V option.