jaaql-middleware-python 5.3.23__py3-none-any.whl → 5.3.24__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.
jaaql/constants.py CHANGED
@@ -291,5 +291,5 @@ ROLE__dba = "dba"
291
291
 
292
292
  PROTOCOL__postgres = "postgresql://"
293
293
 
294
- VERSION = "5.3.23"
294
+ VERSION = "5.3.24"
295
295
 
@@ -625,7 +625,7 @@ DOCUMENTATION__report_sentinel_error = SwaggerDocumentation(
625
625
  name="Report error",
626
626
  description="Logs an application error (user_agent + ip_address encrypted at rest) and triggers Sentinel "
627
627
  "alert processing. Never returns 500 (would otherwise make JAAQL report itself recursively). "
628
- "Any JSON object holding a report key is stored, whatever its Content-Type: a value that does not fit "
628
+ "Any JSON object holding a report key is stored, whatever its Content-Type. A value that does not fit "
629
629
  "Sentinel's error table is adapted (cut, NULL for a line or column out of range, defaults for missing keys, "
630
630
  "unknown keys ignored), with each adaptation listed under 'Ingest adjustments:' in the stored stacktrace; a "
631
631
  "body over 2 MB keeps the start and end of its stacktrace. Refused are only a body holding no JSON object "
@@ -0,0 +1,31 @@
1
+ import os
2
+ import tempfile
3
+ import unittest
4
+ from unittest import mock
5
+
6
+ import jaaql.documentation as documentation
7
+ from jaaql.constants import ENVIRON__sentinel_url
8
+ from jaaql.jaaql import dir_non_builtins
9
+ from jaaql.mvc.controller import JAAQLController
10
+ from jaaql.openapi.swagger_documentation import produce_all_documentation
11
+ from jaaql.test.test_slow_queries import StubModel
12
+
13
+
14
+ class TestDocumentation(unittest.TestCase):
15
+ """
16
+ JAAQL builds and parses the OpenAPI documentation of every route at boot, once the controller has routed them (jaaql.create_app); a
17
+ description its hand-built YAML cannot hold, such as one with ': ' in it, stops every worker before it serves a request
18
+ """
19
+
20
+ def test_every_route_documents_at_boot(self):
21
+ env = {k: v for k, v in os.environ.items() if k != ENVIRON__sentinel_url}
22
+ with mock.patch.dict(os.environ, env, clear=True):
23
+ controller = JAAQLController(StubModel(), True, "http+unix://%2Ftmp%2Fjaaql.sock")
24
+ controller.create_app()
25
+ with tempfile.TemporaryDirectory() as base_path:
26
+ produce_all_documentation(dir_non_builtins(documentation), "http://127.0.0.1/api/", is_prod=True, base_path=base_path)
27
+ self.assertTrue(any(files for _, _, files in os.walk(base_path)))
28
+
29
+
30
+ if __name__ == "__main__":
31
+ unittest.main()
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: jaaql-middleware-python
3
- Version: 5.3.23
3
+ Version: 5.3.24
4
4
  Summary: The jaaql package, allowing for rapid development and deployment of RESTful HTTP applications
5
5
  Home-page: https://github.com/JAAQL/JAAQL-middleware-python
6
6
  Author: Software Quality Measurement and Improvement bv
@@ -1,6 +1,6 @@
1
1
  jaaql/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
2
  jaaql/config_constants.py,sha256=puoR6jfbXw8oXXEfbYNn2ysGwgiGTyuDjOj7F8acsTE,470
3
- jaaql/constants.py,sha256=FWhCSIWN961XaNbP8of_fGv-ztmC0cYIaYM8dYCvbbw,13316
3
+ jaaql/constants.py,sha256=ta-kNZoBlCv235NRBM3gdTil46EACBcqNHd7IRV37fk,13316
4
4
  jaaql/generated_constants.py,sha256=pxmpTux7rrjJH6iqLb-R8RKJ4t0CeoGdnspjH5DiWgU,11327
5
5
  jaaql/jaaql.py,sha256=bfiEW9A8PlZIVjDJd_LOhCLBL8flc_f7w0umR6EWbU4,6614
6
6
  jaaql/patch.py,sha256=VE4B6jA492NCIxNIewbynh92jxVulmRFtB9hNEe6q94,149
@@ -14,7 +14,7 @@ jaaql/db/db_pg_interface.py,sha256=G31vg6NlXGNfPATujGe8B5XZtsPMxqebT0tm9cVmNa8,2
14
14
  jaaql/db/db_utils.py,sha256=GFHr0TiZaT9vlyehebWtK4X7S54Psia8KzeVYyFi0Fk,9422
15
15
  jaaql/db/db_utils_no_circ.py,sha256=G6qea_cJdFnmpAaYain-lyyKhGXTrYPDrly4aeWbyKg,10510
16
16
  jaaql/documentation/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
17
- jaaql/documentation/documentation_internal.py,sha256=Y_MMiH30tuPRDgdE1aoCiVQ0m0_0qW2yam8zByMHyq4,23491
17
+ jaaql/documentation/documentation_internal.py,sha256=Od_cwkHN6OwolXbtl4iWhYdo4_9WQmlvb0nm2VYPNog,23491
18
18
  jaaql/documentation/documentation_public.py,sha256=XU1Smw-1heWhCs-FDqTCTVCkAI2COHEy6fk2fhrwFN4,10932
19
19
  jaaql/documentation/documentation_shared.py,sha256=gTw3rT2hC6LTlJMXnwmxhSTh3xUetIJPtIhldptXF84,6654
20
20
  jaaql/email/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -61,6 +61,7 @@ jaaql/services/shared_var_service.py,sha256=gcaj1x5C5m3DOcV85jrkIe4Uc_C8mW9nNdqv
61
61
  jaaql/test/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
62
62
  jaaql/test/test_call_proc.py,sha256=Tq7DNrm594psl2QxTLk-SYNBqjQ_10thx0d9Oo3IjbA,11309
63
63
  jaaql/test/test_connection_lifecycle.py,sha256=wn0FXaOXmheWWqjLGAOI6w1G2yB6s0UAQXjhnYeg2Yk,36549
64
+ jaaql/test/test_documentation.py,sha256=XGS_lgpG5aPzKANHTNqyoNfpvwGNiPGbg873CSe5pYw,1334
64
65
  jaaql/test/test_execute.py,sha256=ddoiBtfQaBljbEGlVMBrWIaeaQegSW5wwfawiipcfZo,2952
65
66
  jaaql/test/test_oidc_cookies.py,sha256=HQ7JXV8yXT-FXJWQs4SjHqlaL1Nkr7QZ0wdhCLYvCsQ,4525
66
67
  jaaql/test/test_password_login.py,sha256=REnoyZKurJW25YBKJEHVx6uBNQQTwlw1u3Em4uxPGO8,3057
@@ -83,8 +84,8 @@ jaaql/utilities/slow_queries.py,sha256=mNJpWnR0wUt_xYxjpZLvGjSBtDPTZzXvldIz6dsgr
83
84
  jaaql/utilities/utils.py,sha256=nVYVhuHtWSjdaJaXe9eC1Usja56NO-V9SoBIlcHAK8Q,5166
84
85
  jaaql/utilities/utils_no_project_imports.py,sha256=YwcskR15dAqKdEiuF8zGx-tzwWkclSGil_zm_qZ8ylU,4626
85
86
  jaaql/utilities/vault.py,sha256=DudyQNtMtaRLL71IGQX0AI16Tg1id98BHTCQPyUNkmE,2243
86
- jaaql_middleware_python-5.3.23.dist-info/licenses/LICENSE.txt,sha256=wr50eN0TnkrCSuNwyiI81FLZqmrW3q0JqRlVVQIrGA0,18134
87
- jaaql_middleware_python-5.3.23.dist-info/METADATA,sha256=o1eXg4JKRPA5m5IpVH7N57VlaoJJuQQb07fLWo4Z8nA,1977
88
- jaaql_middleware_python-5.3.23.dist-info/WHEEL,sha256=lTU6B6eIfYoiQJTZNc-fyaR6BpL6ehTzU3xGYxn2n8k,91
89
- jaaql_middleware_python-5.3.23.dist-info/top_level.txt,sha256=k5aKVQy77bPyfyNHITvo5m3FqdSAiiXbjT5S9D9KzgU,6
90
- jaaql_middleware_python-5.3.23.dist-info/RECORD,,
87
+ jaaql_middleware_python-5.3.24.dist-info/licenses/LICENSE.txt,sha256=wr50eN0TnkrCSuNwyiI81FLZqmrW3q0JqRlVVQIrGA0,18134
88
+ jaaql_middleware_python-5.3.24.dist-info/METADATA,sha256=cn5QJTVB9nzlQ8BQcu9NMq_27AjG_c06Wn90RP4tPQY,1977
89
+ jaaql_middleware_python-5.3.24.dist-info/WHEEL,sha256=lTU6B6eIfYoiQJTZNc-fyaR6BpL6ehTzU3xGYxn2n8k,91
90
+ jaaql_middleware_python-5.3.24.dist-info/top_level.txt,sha256=k5aKVQy77bPyfyNHITvo5m3FqdSAiiXbjT5S9D9KzgU,6
91
+ jaaql_middleware_python-5.3.24.dist-info/RECORD,,