devnomads 0.4.0__tar.gz → 0.4.1__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.
- {devnomads-0.4.0 → devnomads-0.4.1}/PKG-INFO +1 -1
- {devnomads-0.4.0 → devnomads-0.4.1}/pyproject.toml +1 -1
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/api/client.py +15 -1
- {devnomads-0.4.0 → devnomads-0.4.1}/.flake8 +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/.gitignore +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/.gitlab-ci.yml +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/Makefile +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/README.md +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/openapi.json +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/__init__.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/acme/__init__.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/acme/challenge_server.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/acme/client.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/acme/dns01.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/acme/errors.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/acme/http01.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/acme/keys.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/acme/verify.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/api/__init__.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/api/_services.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/api/credentials.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/api/errors.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/dns/__init__.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/dns/errors.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/dns/names.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/dns/zones.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/src/devnomads/py.typed +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tests/conftest.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tests/test_acme_challenges.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tests/test_acme_client.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tests/test_acme_keys.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tests/test_client.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tests/test_credentials.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tests/test_dns.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tests/test_names.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tests/test_services.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tools/bump_version.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/tools/generate.py +0 -0
- {devnomads-0.4.0 → devnomads-0.4.1}/uv.lock +0 -0
|
@@ -124,12 +124,26 @@ class Client(ResourcesMixin):
|
|
|
124
124
|
status=status,
|
|
125
125
|
detail=_error_detail(response),
|
|
126
126
|
)
|
|
127
|
+
if 300 <= status < 400:
|
|
128
|
+
location = response.headers.get("location", "")
|
|
129
|
+
raise ApiError(
|
|
130
|
+
f"API returned an unexpected HTTP {status} redirect"
|
|
131
|
+
+ (f" to {location}" if location else "")
|
|
132
|
+
+ " - the endpoint or credentials may be misrouted",
|
|
133
|
+
status=status,
|
|
134
|
+
detail=location,
|
|
135
|
+
)
|
|
127
136
|
if status == 204 or not response.content:
|
|
128
137
|
return None
|
|
129
138
|
try:
|
|
130
139
|
return _unwrap(response.json())
|
|
131
140
|
except ValueError as exc:
|
|
132
|
-
|
|
141
|
+
snippet = response.text[:200].strip()
|
|
142
|
+
raise ApiError(
|
|
143
|
+
f"API returned invalid JSON (HTTP {status}): {exc}; "
|
|
144
|
+
f"body starts with: {snippet!r}",
|
|
145
|
+
status=status,
|
|
146
|
+
) from exc
|
|
133
147
|
|
|
134
148
|
def _send(
|
|
135
149
|
self,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|