diracx-testing 0.0.1a38__py3-none-any.whl → 0.0.1a40__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.
diracx/testing/utils.py CHANGED
@@ -184,7 +184,8 @@ class ClientFactory:
184
184
 
185
185
  @staticmethod
186
186
  def enrich_tokens(
187
- access_payload: AccessTokenPayload, refresh_payload: RefreshTokenPayload
187
+ access_payload: AccessTokenPayload,
188
+ refresh_payload: RefreshTokenPayload | None,
188
189
  ):
189
190
 
190
191
  return {"PolicySpecific": "OpenAccessForTest"}, {}
@@ -218,6 +219,12 @@ class ClientFactory:
218
219
  for e in select_from_extension(group="diracx.access_policies")
219
220
  }
220
221
 
222
+ config_source = ConfigSource.create_from_url(
223
+ backend_url=f"git+file://{with_config_repo}"
224
+ )
225
+ # Warm the cache to avoid 503 errors
226
+ config_source.read_config()
227
+
221
228
  self.app = create_app_inner(
222
229
  enabled_systems=enabled_systems,
223
230
  all_service_settings=[
@@ -227,9 +234,7 @@ class ClientFactory:
227
234
  ],
228
235
  database_urls=database_urls,
229
236
  os_database_conn_kwargs=os_database_conn_kwargs,
230
- config_source=ConfigSource.create_from_url(
231
- backend_url=f"git+file://{with_config_repo}"
232
- ),
237
+ config_source=config_source,
233
238
  all_access_policies=all_access_policies,
234
239
  )
235
240
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: diracx-testing
3
- Version: 0.0.1a38
3
+ Version: 0.0.1a40
4
4
  Summary: TODO
5
5
  License: GPL-3.0-only
6
6
  Classifier: Intended Audience :: Science/Research
@@ -5,8 +5,8 @@ diracx/testing/entrypoints.py,sha256=ql7byyUOnUBdDoiN5xznlUTQSbD1YCNy4UF5t9MBhgc
5
5
  diracx/testing/mock_osdb.py,sha256=2pl9yKV1-e5kzf6meBZnhoc1i0ySAJ8IdnP3r1bOwcI,6033
6
6
  diracx/testing/osdb.py,sha256=m6mUBLnGOoQLTCIBie9P2GhmLMybrgzIrlIYfhF1_Ss,3230
7
7
  diracx/testing/routers.py,sha256=UW-TnikMQgcNxF5sUZD5DWoucGiCpP6s8mYmuahDiSc,979
8
- diracx/testing/utils.py,sha256=T3tTzEOhmibcIu6TPwvoaZ6lFgHlU0t9FDHSetKP5EI,24341
9
- diracx_testing-0.0.1a38.dist-info/METADATA,sha256=G-Ttvj6f4VDYScnhTm2AV2c00R6CxZskmMZsAl0S4U4,634
10
- diracx_testing-0.0.1a38.dist-info/WHEEL,sha256=CmyFI0kx5cdEMTLiONQRbGQwjIoR1aIYB7eCAQ4KPJ0,91
11
- diracx_testing-0.0.1a38.dist-info/top_level.txt,sha256=vJx10tdRlBX3rF2Psgk5jlwVGZNcL3m_7iQWwgPXt-U,7
12
- diracx_testing-0.0.1a38.dist-info/RECORD,,
8
+ diracx/testing/utils.py,sha256=smjFeGWeIr5tvb2koMj9tsCxtN3nt8zrR9tvsUpSXak,24477
9
+ diracx_testing-0.0.1a40.dist-info/METADATA,sha256=0GdyOm3cSopEMzV7o6cHpkhyIE4uToI532V_nOk0a-w,634
10
+ diracx_testing-0.0.1a40.dist-info/WHEEL,sha256=CmyFI0kx5cdEMTLiONQRbGQwjIoR1aIYB7eCAQ4KPJ0,91
11
+ diracx_testing-0.0.1a40.dist-info/top_level.txt,sha256=vJx10tdRlBX3rF2Psgk5jlwVGZNcL3m_7iQWwgPXt-U,7
12
+ diracx_testing-0.0.1a40.dist-info/RECORD,,