c2cwsgiutils 6.2.0.dev66__py3-none-any.whl → 6.2.0.dev68__py3-none-any.whl
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.
- c2cwsgiutils/acceptance/connection.py +3 -3
- c2cwsgiutils/acceptance/image.py +9 -9
- {c2cwsgiutils-6.2.0.dev66.dist-info → c2cwsgiutils-6.2.0.dev68.dist-info}/METADATA +31 -32
- {c2cwsgiutils-6.2.0.dev66.dist-info → c2cwsgiutils-6.2.0.dev68.dist-info}/RECORD +7 -7
- {c2cwsgiutils-6.2.0.dev66.dist-info → c2cwsgiutils-6.2.0.dev68.dist-info}/WHEEL +1 -1
- {c2cwsgiutils-6.2.0.dev66.dist-info → c2cwsgiutils-6.2.0.dev68.dist-info}/LICENSE +0 -0
- {c2cwsgiutils-6.2.0.dev66.dist-info → c2cwsgiutils-6.2.0.dev68.dist-info}/entry_points.txt +0 -0
@@ -267,7 +267,7 @@ def _get_json(r: requests.Response) -> Any:
|
|
267
267
|
return None
|
268
268
|
else:
|
269
269
|
content_type = r.headers["Content-Type"].split(";")[0]
|
270
|
-
assert content_type == "application/json" or content_type.endswith(
|
271
|
-
"
|
272
|
-
)
|
270
|
+
assert content_type == "application/json" or content_type.endswith("+json"), (
|
271
|
+
f"{r.status_code}, {content_type}, {r.text}"
|
272
|
+
)
|
273
273
|
return r.json()
|
c2cwsgiutils/acceptance/image.py
CHANGED
@@ -135,9 +135,9 @@ def check_image( # pylint: disable=too-many-locals,too-many-statements
|
|
135
135
|
# Convert to boolean
|
136
136
|
mask = mask == 0
|
137
137
|
|
138
|
-
assert (
|
139
|
-
|
140
|
-
)
|
138
|
+
assert mask.shape[0] == image_to_check.shape[0] and mask.shape[1] == image_to_check.shape[1], (
|
139
|
+
f"Mask and image should have the same shape ({mask.shape} != {image_to_check.shape})"
|
140
|
+
)
|
141
141
|
image_to_check[mask] = background_color
|
142
142
|
|
143
143
|
if not os.path.exists(result_folder):
|
@@ -153,14 +153,14 @@ def check_image( # pylint: disable=too-many-locals,too-many-statements
|
|
153
153
|
expected = normalize_image(expected)
|
154
154
|
|
155
155
|
if mask is not None:
|
156
|
-
assert (
|
157
|
-
expected
|
158
|
-
)
|
156
|
+
assert expected.shape[0] == mask.shape[0] and expected.shape[1] == mask.shape[1], (
|
157
|
+
f"Mask and expected image should have the same shape ({mask.shape} != {expected.shape})"
|
158
|
+
)
|
159
159
|
expected[mask] = background_color
|
160
160
|
|
161
|
-
assert (
|
162
|
-
expected.shape
|
163
|
-
)
|
161
|
+
assert expected.shape == image_to_check.shape, (
|
162
|
+
f"Images have different shapes expected {expected.shape} != actual {image_to_check.shape}"
|
163
|
+
)
|
164
164
|
score, diff = skimage.metrics.structural_similarity(
|
165
165
|
expected, image_to_check, multichannel=True, full=True, channel_axis=2
|
166
166
|
)
|
@@ -1,13 +1,12 @@
|
|
1
|
-
Metadata-Version: 2.
|
1
|
+
Metadata-Version: 2.3
|
2
2
|
Name: c2cwsgiutils
|
3
|
-
Version: 6.2.0.
|
3
|
+
Version: 6.2.0.dev68
|
4
4
|
Summary: Common utilities for Camptocamp WSGI applications
|
5
|
-
Home-page: https://github.com/camptocamp/c2cwsgiutils
|
6
5
|
License: BSD-2-Clause
|
7
6
|
Keywords: geo,gis,sqlalchemy,orm,wsgi
|
8
7
|
Author: Camptocamp
|
9
8
|
Author-email: info@camptocamp.com
|
10
|
-
Requires-Python: >=3.10
|
9
|
+
Requires-Python: >=3.10,<4.0
|
11
10
|
Classifier: Development Status :: 5 - Production/Stable
|
12
11
|
Classifier: Environment :: Plugins
|
13
12
|
Classifier: Framework :: Pyramid
|
@@ -35,34 +34,34 @@ Provides-Extra: test-images
|
|
35
34
|
Provides-Extra: tests
|
36
35
|
Provides-Extra: waitress
|
37
36
|
Provides-Extra: webserver
|
38
|
-
Requires-Dist: Paste ; extra == "standard" or extra == "waitress" or extra == "all"
|
39
|
-
Requires-Dist: SQLAlchemy ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
40
|
-
Requires-Dist: SQLAlchemy-Utils ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
41
|
-
Requires-Dist: alembic ; extra == "standard" or extra == "alembic" or extra == "all"
|
42
|
-
Requires-Dist: boltons ; extra == "tests" or extra == "all"
|
43
|
-
Requires-Dist: cee_syslog_handler
|
44
|
-
Requires-Dist: cornice ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
45
|
-
Requires-Dist: coverage ; extra == "debug" or extra == "all"
|
46
|
-
Requires-Dist: gunicorn ; extra == "standard" or extra == "webserver" or extra == "all"
|
47
|
-
Requires-Dist: lxml ; extra == "tests" or extra == "all"
|
48
|
-
Requires-Dist: objgraph ; extra == "debug" or extra == "all"
|
49
|
-
Requires-Dist: prometheus-client ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
50
|
-
Requires-Dist: psutil ; extra == "debug" or extra == "all"
|
51
|
-
Requires-Dist: psycopg2 ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
52
|
-
Requires-Dist: pyjwt ; extra == "standard" or extra == "oauth2" or extra == "all"
|
53
|
-
Requires-Dist: pyramid ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
54
|
-
Requires-Dist: pyramid-tm ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
55
|
-
Requires-Dist: pyramid_mako ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
56
|
-
Requires-Dist: pyyaml
|
57
|
-
Requires-Dist: redis ; extra == "standard" or extra == "broadcast" or extra == "all"
|
58
|
-
Requires-Dist: requests
|
59
|
-
Requires-Dist: requests-oauthlib ; extra == "standard" or extra == "oauth2" or extra == "all"
|
60
|
-
Requires-Dist: scikit-image ; extra == "test-images"
|
61
|
-
Requires-Dist: sentry-sdk ; extra == "standard" or extra == "sentry" or extra == "all"
|
62
|
-
Requires-Dist: ujson
|
63
|
-
Requires-Dist: waitress ; extra == "standard" or extra == "dev" or extra == "waitress" or extra == "all"
|
64
|
-
Requires-Dist: zope.interface ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
65
|
-
Requires-Dist: zope.sqlalchemy ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
37
|
+
Requires-Dist: Paste (==3.10.1) ; extra == "standard" or extra == "waitress" or extra == "all"
|
38
|
+
Requires-Dist: SQLAlchemy (==2.0.37) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
39
|
+
Requires-Dist: SQLAlchemy-Utils (==0.41.2) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
40
|
+
Requires-Dist: alembic (==1.14.1) ; extra == "standard" or extra == "alembic" or extra == "all"
|
41
|
+
Requires-Dist: boltons (==24.1.0) ; extra == "tests" or extra == "all"
|
42
|
+
Requires-Dist: cee_syslog_handler (==0.6.0)
|
43
|
+
Requires-Dist: cornice (==6.1.0) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
44
|
+
Requires-Dist: coverage (==7.6.10) ; extra == "debug" or extra == "all"
|
45
|
+
Requires-Dist: gunicorn (==23.0.0) ; extra == "standard" or extra == "webserver" or extra == "all"
|
46
|
+
Requires-Dist: lxml (==5.3.0) ; extra == "tests" or extra == "all"
|
47
|
+
Requires-Dist: objgraph (==3.6.2) ; extra == "debug" or extra == "all"
|
48
|
+
Requires-Dist: prometheus-client (==0.21.1) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
49
|
+
Requires-Dist: psutil (==6.1.1) ; extra == "debug" or extra == "all"
|
50
|
+
Requires-Dist: psycopg2 (==2.9.10) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
51
|
+
Requires-Dist: pyjwt (==2.10.1) ; extra == "standard" or extra == "oauth2" or extra == "all"
|
52
|
+
Requires-Dist: pyramid (==2.0.2) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
53
|
+
Requires-Dist: pyramid-tm (==2.6) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
54
|
+
Requires-Dist: pyramid_mako (==1.1.0) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
55
|
+
Requires-Dist: pyyaml (==6.0.2)
|
56
|
+
Requires-Dist: redis (==5.2.1) ; extra == "standard" or extra == "broadcast" or extra == "all"
|
57
|
+
Requires-Dist: requests (==2.32.3)
|
58
|
+
Requires-Dist: requests-oauthlib (==2.0.0) ; extra == "standard" or extra == "oauth2" or extra == "all"
|
59
|
+
Requires-Dist: scikit-image (==0.25.1) ; extra == "test-images"
|
60
|
+
Requires-Dist: sentry-sdk (==2.20.0) ; extra == "standard" or extra == "sentry" or extra == "all"
|
61
|
+
Requires-Dist: ujson (==5.10.0)
|
62
|
+
Requires-Dist: waitress (==3.0.2) ; extra == "standard" or extra == "dev" or extra == "waitress" or extra == "all"
|
63
|
+
Requires-Dist: zope.interface (==7.2) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
64
|
+
Requires-Dist: zope.sqlalchemy (==3.1) ; extra == "standard" or extra == "webserver" or extra == "waitress" or extra == "all"
|
66
65
|
Project-URL: Repository, https://github.com/camptocamp/c2cwsgiutils
|
67
66
|
Description-Content-Type: text/markdown
|
68
67
|
|
@@ -1,7 +1,7 @@
|
|
1
1
|
c2cwsgiutils/__init__.py,sha256=HVSc-4O8i2aB0ozEI4AI8Xsb-4S6fAwhl8uRhv-DsFg,4057
|
2
2
|
c2cwsgiutils/acceptance/__init__.py,sha256=5PeqPHxAPMRbZpKk1XlC9RCyotegSsKVfPxADYAgG7w,1502
|
3
|
-
c2cwsgiutils/acceptance/connection.py,sha256=
|
4
|
-
c2cwsgiutils/acceptance/image.py,sha256=
|
3
|
+
c2cwsgiutils/acceptance/connection.py,sha256=y9Gs4lX2PfL6GyUrskXLYh_PtCsfF0X6UGXcm1A9GcY,9836
|
4
|
+
c2cwsgiutils/acceptance/image.py,sha256=cmXFrQ12iH8cs8ZHkKaEiusDE5WJAl-LLiM5xV4hWhs,9290
|
5
5
|
c2cwsgiutils/acceptance/package-lock.json,sha256=htNAsPGRVu8mHtsZ0FRtJnB7lgLLuV9n61yTCNRIZIA,42615
|
6
6
|
c2cwsgiutils/acceptance/package.json,sha256=ClHsOOzzwKrN7PL-7bcfIGiojA3MNBrk6fP_62soCuw,101
|
7
7
|
c2cwsgiutils/acceptance/print.py,sha256=DOPDHUP9wfM75qiPYhFI1P3awQKIBH-edO_TmhCjT8k,2568
|
@@ -60,8 +60,8 @@ c2cwsgiutils/stats_pyramid/_db_spy.py,sha256=A61t6VKIrRRIjbyZTldmAUl_Q3ZDVFYqyxj
|
|
60
60
|
c2cwsgiutils/stats_pyramid/_pyramid_spy.py,sha256=GnJRlLSAPl4PwQH5jfmc2OX5Hz9MSRRVJT2VcqkniVE,3518
|
61
61
|
c2cwsgiutils/templates/index.html.mako,sha256=cK8qGBDeQG5SiJJCfvL0oKpgacr7dPKx634AAQivmjA,1416
|
62
62
|
c2cwsgiutils/version.py,sha256=7H3URblj26Ql0bL3eXtP0LSRBeW4HbEsQ8O_BfWNr90,3124
|
63
|
-
c2cwsgiutils-6.2.0.
|
64
|
-
c2cwsgiutils-6.2.0.
|
65
|
-
c2cwsgiutils-6.2.0.
|
66
|
-
c2cwsgiutils-6.2.0.
|
67
|
-
c2cwsgiutils-6.2.0.
|
63
|
+
c2cwsgiutils-6.2.0.dev68.dist-info/LICENSE,sha256=6bEOU0n7ued3SA-DQCsHQaACONMMRzGHmH5XhDVeD-U,1304
|
64
|
+
c2cwsgiutils-6.2.0.dev68.dist-info/METADATA,sha256=x8S5CyNRD6dcp-6yl84ES5v-G-iE0YFQu9RH9_HYOQ0,36598
|
65
|
+
c2cwsgiutils-6.2.0.dev68.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
|
66
|
+
c2cwsgiutils-6.2.0.dev68.dist-info/entry_points.txt,sha256=ujgqMTL1awN9qDg8WXmrF7m0fgR-hslUM6zKH86pvy0,703
|
67
|
+
c2cwsgiutils-6.2.0.dev68.dist-info/RECORD,,
|
File without changes
|
File without changes
|