hdx-python-country 3.9.8__tar.gz → 4.0.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/.pre-commit-config.yaml +5 -4
  2. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/PKG-INFO +3 -3
  3. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/documentation/index.md +2 -0
  4. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/hatch.toml +1 -1
  5. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/pyproject.toml +2 -2
  6. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/requirements.txt +28 -126
  7. hdx_python_country-4.0.0/ruff.toml +10 -0
  8. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/src/hdx/location/_version.py +2 -2
  9. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/src/hdx/location/adminlevel.py +103 -105
  10. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/src/hdx/location/country.py +146 -149
  11. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/src/hdx/location/currency.py +69 -69
  12. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/src/hdx/location/int_timestamp.py +2 -2
  13. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/src/hdx/location/wfp_api.py +21 -22
  14. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/src/hdx/location/wfp_exchangerates.py +14 -14
  15. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/hdx/location/test_adminlevel.py +3 -3
  16. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/hdx/location/test_wfp_exchangerates.py +5 -4
  17. hdx_python_country-3.9.8/ruff.toml +0 -15
  18. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/.coveragerc +0 -0
  19. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/.github/workflows/publish.yaml +0 -0
  20. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/.github/workflows/run-python-tests.yaml +0 -0
  21. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/.gitignore +0 -0
  22. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/LICENSE +0 -0
  23. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/README.md +0 -0
  24. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/documentation/.readthedocs.yaml +0 -0
  25. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/documentation/mkdocs.yaml +0 -0
  26. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/pytest.ini +0 -0
  27. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/src/hdx/location/Countries & Territories Taxonomy MVP - C&T Taxonomy with HXL Tags.csv +0 -0
  28. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/src/hdx/location/__init__.py +0 -0
  29. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/adminlevel.yaml +0 -0
  30. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/adminlevelparent.yaml +0 -0
  31. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/download-global-pcode-lengths.csv +0 -0
  32. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/download-global-pcodes-adm-1-2.csv +0 -0
  33. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/secondary_historic_rates.csv +0 -0
  34. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/secondary_rates.json +0 -0
  35. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_List_1.json +0 -0
  36. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_List_2.json +0 -0
  37. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_1.json +0 -0
  38. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_10.json +0 -0
  39. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_2.json +0 -0
  40. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_3.json +0 -0
  41. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_4.json +0 -0
  42. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_5.json +0 -0
  43. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_6.json +0 -0
  44. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_7.json +0 -0
  45. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_8.json +0 -0
  46. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/fixtures/wfp/Currency_UsdIndirectQuotation_9.json +0 -0
  47. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/hdx/location/Countries_UZB_Deleted.csv +0 -0
  48. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/hdx/location/__init__.py +0 -0
  49. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/hdx/location/conftest.py +0 -0
  50. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/hdx/location/test_country.py +1 -1
  51. {hdx_python_country-3.9.8 → hdx_python_country-4.0.0}/tests/hdx/location/test_currency.py +3 -3
@@ -2,13 +2,13 @@ default_language_version:
2
2
  python: python3.13
3
3
  repos:
4
4
  - repo: https://github.com/pre-commit/pre-commit-hooks
5
- rev: v5.0.0
5
+ rev: v6.0.0
6
6
  hooks:
7
7
  - id: trailing-whitespace
8
8
  - id: end-of-file-fixer
9
9
  - id: check-ast
10
10
  - repo: https://github.com/astral-sh/ruff-pre-commit
11
- rev: v0.12.0
11
+ rev: v0.14.10
12
12
  hooks:
13
13
  # Run the linter.
14
14
  - id: ruff-check
@@ -16,10 +16,11 @@ repos:
16
16
  # Run the formatter.
17
17
  - id: ruff-format
18
18
  - repo: https://github.com/astral-sh/uv-pre-commit
19
- rev: 0.7.14
19
+ rev: 0.9.22
20
20
  hooks:
21
21
  # Run the pip compile
22
22
  - id: pip-compile
23
23
  name: pip-compile requirements.txt
24
24
  files: pyproject.toml
25
- args: [ pyproject.toml, --resolver=backtracking, --all-extras, --upgrade, -q, -o, requirements.txt ]
25
+ args: [ pyproject.toml, --resolver=backtracking, --upgrade, -q,
26
+ -o, requirements.txt ]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: hdx-python-country
3
- Version: 3.9.8
3
+ Version: 4.0.0
4
4
  Summary: HDX Python country code and exchange rate (fx) utilities
5
5
  Project-URL: Homepage, https://github.com/OCHA-DAP/hdx-python-country
6
6
  Author: Michael Rans
@@ -24,8 +24,8 @@ Classifier: Programming Language :: Python :: 3.10
24
24
  Classifier: Programming Language :: Python :: 3.11
25
25
  Classifier: Programming Language :: Python :: 3.12
26
26
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
27
- Requires-Python: >=3.8
28
- Requires-Dist: hdx-python-utilities>=3.9.2
27
+ Requires-Python: >=3.10
28
+ Requires-Dist: hdx-python-utilities>=4.0.0
29
29
  Requires-Dist: libhxl>=5.2.2
30
30
  Requires-Dist: tenacity
31
31
  Provides-Extra: dev
@@ -42,6 +42,8 @@ The code for the library is [here](https://github.com/OCHA-DAP/hdx-python-countr
42
42
  The library has detailed API documentation which can be found in the menu at the top.
43
43
 
44
44
  ## Breaking Changes
45
+ From 4.0.0, Python 3.10 or later is required
46
+
45
47
  From 3.9.2, must call Currency.setup before using Currency methods.
46
48
 
47
49
  From 3.7.5, removed clean_name function. There is now a function normalise in
@@ -34,4 +34,4 @@ run = """
34
34
 
35
35
  [envs.hatch-static-analysis]
36
36
  config-path = "none"
37
- dependencies = ["ruff==0.9.10"]
37
+ dependencies = ["ruff==0.14.10"]
@@ -31,10 +31,10 @@ classifiers = [
31
31
  "Operating System :: MacOS",
32
32
  "Operating System :: Microsoft :: Windows",
33
33
  ]
34
- requires-python = ">=3.8"
34
+ requires-python = ">=3.10"
35
35
 
36
36
  dependencies = [
37
- "hdx-python-utilities>=3.9.2",
37
+ "hdx-python-utilities>=4.0.0",
38
38
  "libhxl>=5.2.2",
39
39
  "tenacity",
40
40
  ]
@@ -1,71 +1,42 @@
1
1
  # This file was autogenerated by uv via the following command:
2
- # uv pip compile pyproject.toml --resolver=backtracking --all-extras -o requirements.txt
2
+ # uv pip compile pyproject.toml --resolver=backtracking -o requirements.txt
3
3
  annotated-types==0.7.0
4
4
  # via pydantic
5
- astdoc==1.3.2
6
- # via mkapi
7
- attrs==25.3.0
5
+ attrs==25.4.0
8
6
  # via
9
7
  # frictionless
10
8
  # jsonlines
11
9
  # jsonschema
12
10
  # referencing
13
- babel==2.17.0
14
- # via mkdocs-material
15
- backrefs==5.9
16
- # via mkdocs-material
17
- certifi==2025.8.3
11
+ certifi==2026.1.4
18
12
  # via requests
19
- cfgv==3.4.0
20
- # via pre-commit
21
13
  chardet==5.2.0
22
14
  # via frictionless
23
- charset-normalizer==3.4.3
15
+ charset-normalizer==3.4.4
24
16
  # via requests
25
- click==8.2.1
26
- # via
27
- # mkdocs
28
- # mkdocs-material
29
- # typer
30
- colorama==0.4.6
31
- # via mkdocs-material
32
- coverage==7.10.7
33
- # via pytest-cov
34
- distlib==0.4.0
35
- # via virtualenv
17
+ click==8.3.1
18
+ # via typer
36
19
  et-xmlfile==2.0.0
37
20
  # via openpyxl
38
- filelock==3.19.1
39
- # via virtualenv
40
21
  frictionless==5.18.1
41
22
  # via hdx-python-utilities
42
- ghp-import==2.1.0
43
- # via mkdocs
44
- hdx-python-utilities==3.9.2
23
+ hdx-python-utilities==4.0.0
45
24
  # via hdx-python-country (pyproject.toml)
46
- humanize==4.13.0
25
+ humanize==4.15.0
47
26
  # via frictionless
48
- identify==2.6.14
49
- # via pre-commit
50
- idna==3.10
27
+ idna==3.11
51
28
  # via requests
52
- ijson==3.4.0
29
+ ijson==3.4.0.post0
53
30
  # via hdx-python-utilities
54
- iniconfig==2.1.0
55
- # via pytest
56
31
  isodate==0.7.2
57
32
  # via frictionless
58
33
  jinja2==3.1.6
59
- # via
60
- # frictionless
61
- # mkapi
62
- # mkdocs
63
- # mkdocs-material
34
+ # via frictionless
64
35
  jsonlines==4.0.0
65
36
  # via hdx-python-utilities
66
37
  jsonpath-ng==1.7.0
67
38
  # via libhxl
68
- jsonschema==4.25.1
39
+ jsonschema==4.26.0
69
40
  # via
70
41
  # frictionless
71
42
  # tableschema-to-template
@@ -75,108 +46,46 @@ libhxl==5.2.2
75
46
  # via hdx-python-country (pyproject.toml)
76
47
  loguru==0.7.3
77
48
  # via hdx-python-utilities
78
- markdown==3.9
79
- # via
80
- # mkdocs
81
- # mkdocs-material
82
- # pymdown-extensions
83
49
  markdown-it-py==4.0.0
84
50
  # via rich
85
- marko==2.2.0
51
+ marko==2.2.2
86
52
  # via frictionless
87
- markupsafe==3.0.2
88
- # via
89
- # jinja2
90
- # mkdocs
53
+ markupsafe==3.0.3
54
+ # via jinja2
91
55
  mdurl==0.1.2
92
56
  # via markdown-it-py
93
- mergedeep==1.3.4
94
- # via
95
- # mkdocs
96
- # mkdocs-get-deps
97
- mkapi==4.4.5
98
- # via hdx-python-country (pyproject.toml)
99
- mkdocs==1.6.1
100
- # via
101
- # mkapi
102
- # mkdocs-material
103
- mkdocs-get-deps==0.2.0
104
- # via mkdocs
105
- mkdocs-material==9.6.20
106
- # via mkapi
107
- mkdocs-material-extensions==1.3.1
108
- # via mkdocs-material
109
- nodeenv==1.9.1
110
- # via pre-commit
111
57
  openpyxl==3.1.5
112
58
  # via hdx-python-utilities
113
- packaging==25.0
114
- # via
115
- # mkdocs
116
- # pytest
117
- paginate==0.5.7
118
- # via mkdocs-material
119
- pathspec==0.12.1
120
- # via mkdocs
121
59
  petl==1.7.17
122
60
  # via frictionless
123
- platformdirs==4.4.0
124
- # via
125
- # mkdocs-get-deps
126
- # virtualenv
127
- pluggy==1.6.0
128
- # via
129
- # pytest
130
- # pytest-cov
131
61
  ply==3.11
132
62
  # via
133
63
  # jsonpath-ng
134
64
  # libhxl
135
- pre-commit==4.3.0
136
- # via hdx-python-country (pyproject.toml)
137
- pydantic==2.11.9
65
+ pydantic==2.12.5
138
66
  # via frictionless
139
- pydantic-core==2.33.2
67
+ pydantic-core==2.41.5
140
68
  # via pydantic
141
69
  pygments==2.19.2
142
- # via
143
- # mkdocs-material
144
- # pytest
145
- # rich
146
- pymdown-extensions==10.16.1
147
- # via mkdocs-material
70
+ # via rich
148
71
  pyphonetics==0.5.3
149
72
  # via hdx-python-utilities
150
- pytest==8.4.2
151
- # via
152
- # hdx-python-country (pyproject.toml)
153
- # pytest-cov
154
- pytest-cov==7.0.0
155
- # via hdx-python-country (pyproject.toml)
156
73
  python-dateutil==2.9.0.post0
157
74
  # via
158
75
  # frictionless
159
- # ghp-import
160
76
  # hdx-python-utilities
161
77
  # libhxl
162
78
  python-io-wrapper==0.3.1
163
79
  # via libhxl
164
80
  python-slugify==8.0.4
165
81
  # via frictionless
166
- pyyaml==6.0.2
82
+ pyyaml==6.0.3
167
83
  # via
168
84
  # frictionless
169
- # mkdocs
170
- # mkdocs-get-deps
171
- # pre-commit
172
- # pymdown-extensions
173
- # pyyaml-env-tag
174
85
  # tableschema-to-template
175
- pyyaml-env-tag==1.1
176
- # via mkdocs
177
86
  ratelimit==2.2.1
178
87
  # via hdx-python-utilities
179
- referencing==0.36.2
88
+ referencing==0.37.0
180
89
  # via
181
90
  # jsonschema
182
91
  # jsonschema-specifications
@@ -184,29 +93,26 @@ requests==2.32.5
184
93
  # via
185
94
  # frictionless
186
95
  # libhxl
187
- # mkdocs-material
188
96
  # requests-file
189
- requests-file==2.1.0
97
+ requests-file==3.0.1
190
98
  # via hdx-python-utilities
191
99
  rfc3986==2.0.0
192
100
  # via frictionless
193
- rich==14.1.0
101
+ rich==14.2.0
194
102
  # via typer
195
- rpds-py==0.27.1
103
+ rpds-py==0.30.0
196
104
  # via
197
105
  # jsonschema
198
106
  # referencing
199
- ruamel-yaml==0.18.15
107
+ ruamel-yaml==0.19.1
200
108
  # via hdx-python-utilities
201
- ruamel-yaml-clib==0.2.12
202
- # via ruamel-yaml
203
109
  shellingham==1.5.4
204
110
  # via typer
205
111
  simpleeval==1.0.3
206
112
  # via frictionless
207
113
  six==1.17.0
208
114
  # via python-dateutil
209
- structlog==25.4.0
115
+ structlog==25.5.0
210
116
  # via libhxl
211
117
  tableschema-to-template==0.0.13
212
118
  # via hdx-python-utilities
@@ -216,7 +122,7 @@ tenacity==9.1.2
216
122
  # via hdx-python-country (pyproject.toml)
217
123
  text-unidecode==1.3
218
124
  # via python-slugify
219
- typer==0.19.1
125
+ typer==0.21.1
220
126
  # via frictionless
221
127
  typing-extensions==4.15.0
222
128
  # via
@@ -225,22 +131,18 @@ typing-extensions==4.15.0
225
131
  # pydantic-core
226
132
  # typer
227
133
  # typing-inspection
228
- typing-inspection==0.4.1
134
+ typing-inspection==0.4.2
229
135
  # via pydantic
230
136
  unidecode==1.4.0
231
137
  # via
232
138
  # libhxl
233
139
  # pyphonetics
234
- urllib3==2.5.0
140
+ urllib3==2.6.3
235
141
  # via
236
142
  # libhxl
237
143
  # requests
238
144
  validators==0.35.0
239
145
  # via frictionless
240
- virtualenv==20.34.0
241
- # via pre-commit
242
- watchdog==6.0.0
243
- # via mkdocs
244
146
  wheel==0.45.1
245
147
  # via libhxl
246
148
  xlrd==2.0.2
@@ -0,0 +1,10 @@
1
+ target-version = "py310"
2
+ src = ["src"]
3
+ exclude = ["_version.py"]
4
+
5
+ [lint]
6
+ # List of rules: https://docs.astral.sh/ruff/rules/
7
+ extend-select = [
8
+ "I", # isort
9
+ "UP" # Upgrade Python
10
+ ]
@@ -28,7 +28,7 @@ version_tuple: VERSION_TUPLE
28
28
  commit_id: COMMIT_ID
29
29
  __commit_id__: COMMIT_ID
30
30
 
31
- __version__ = version = '3.9.8'
32
- __version_tuple__ = version_tuple = (3, 9, 8)
31
+ __version__ = version = '4.0.0'
32
+ __version_tuple__ = version_tuple = (4, 0, 0)
33
33
 
34
34
  __commit_id__ = commit_id = None