pulp-python 3.27.5__py3-none-any.whl → 3.27.6__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.
@@ -12,7 +12,7 @@ class PulpPythonPluginAppConfig(PulpPluginAppConfig):
12
12
 
13
13
  name = "pulp_python.app"
14
14
  label = "python"
15
- version = "3.27.5"
15
+ version = "3.27.6"
16
16
  python_package_name = "pulp-python"
17
17
  domain_compatible = True
18
18
 
@@ -10,7 +10,6 @@ from bandersnatch.master import Master
10
10
  from bandersnatch.mirror import Mirror
11
11
  from lxml.etree import LxmlError
12
12
  from packaging.requirements import Requirement
13
- from pypi_attestations import Provenance
14
13
  from pypi_simple import IndexPage
15
14
  from rest_framework import serializers
16
15
 
@@ -28,6 +27,7 @@ from pulp_python.app.models import (
28
27
  PythonPackageContent,
29
28
  PythonRemote,
30
29
  )
30
+ from pulp_python.app.provenance import Provenance
31
31
  from pulp_python.app.utils import PYPI_LAST_SERIAL, aget_remote_simple_page, parse_metadata
32
32
 
33
33
  logger = logging.getLogger(__name__)
@@ -154,6 +154,54 @@ def test_attestation_sync_upload(python_bindings, twine_package, download_python
154
154
  assert att_bundle["publisher"]["kind"] == "Pulp User"
155
155
 
156
156
 
157
+ @pytest.mark.parallel
158
+ def test_sync_pulp_created_provenance(
159
+ domain_factory,
160
+ python_bindings,
161
+ twine_package,
162
+ python_repo_factory,
163
+ python_distribution_factory,
164
+ python_remote_factory,
165
+ python_repo_with_sync,
166
+ python_content_summary,
167
+ monitor_task,
168
+ ):
169
+ """Test syncing provenance across domains from a Pulp upload."""
170
+ source_domain = domain_factory()
171
+ attestations = get_attestations(twine_package.provenance_url)
172
+ source_repo = python_repo_factory(pulp_domain=source_domain.name)
173
+ body = {
174
+ "relative_path": twine_package.filename,
175
+ "file_url": twine_package.url,
176
+ "attestations": json.dumps(attestations),
177
+ "repository": source_repo.pulp_href,
178
+ }
179
+ task = python_bindings.ContentPackagesApi.create(pulp_domain=source_domain.name, **body).task
180
+ monitor_task(task)
181
+
182
+ source_distro = python_distribution_factory(
183
+ repository=source_repo, pulp_domain=source_domain.name
184
+ )
185
+ dest_domain = domain_factory()
186
+ remote = python_remote_factory(
187
+ url=source_distro.base_url,
188
+ provenance=True,
189
+ includes=[f"twine=={twine_package.version}"],
190
+ pulp_domain=dest_domain.name,
191
+ )
192
+ dest_repo = python_repo_with_sync(remote=remote, pulp_domain=dest_domain.name)
193
+
194
+ summary = python_content_summary(repository_version=dest_repo.latest_version_href)
195
+ assert summary.present["python.provenance"]["count"] == 1
196
+
197
+ provs = python_bindings.ContentProvenanceApi.list(
198
+ repository_version=dest_repo.latest_version_href,
199
+ pulp_domain=dest_domain.name,
200
+ )
201
+ assert provs.count == 1
202
+ assert provs.results[0].provenance["attestation_bundles"][0]["publisher"]["kind"] == "Pulp User"
203
+
204
+
157
205
  def test_attestation_twine_upload(
158
206
  pulpcore_bindings,
159
207
  python_content_summary,
@@ -245,8 +245,9 @@ def test_simple_redirect_with_publications(
245
245
  assert response.url == str(urljoin(pulp_content_url, f"{distro.base_path}/simple/"))
246
246
 
247
247
 
248
- @pytest.mark.parallel
249
- def test_pypi_json(python_remote_factory, python_repo_with_sync, python_distribution_factory):
248
+ def test_pypi_json(
249
+ delete_orphans_pre, python_remote_factory, python_repo_with_sync, python_distribution_factory
250
+ ):
250
251
  """Checks the data of `pypi/{package_name}/json` endpoint."""
251
252
  remote = python_remote_factory(policy="immediate")
252
253
  repo = python_repo_with_sync(remote)
@@ -260,8 +261,8 @@ def test_pypi_json(python_remote_factory, python_repo_with_sync, python_distribu
260
261
  assert_pypi_json(response.json())
261
262
 
262
263
 
263
- @pytest.mark.parallel
264
264
  def test_pypi_json_content_app(
265
+ delete_orphans_pre,
265
266
  python_remote_factory,
266
267
  python_repo_with_sync,
267
268
  python_publication_factory,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pulp-python
3
- Version: 3.27.5
3
+ Version: 3.27.6
4
4
  Summary: pulp-python plugin for the Pulp Project
5
5
  Author-email: Pulp Team <pulp-list@redhat.com>
6
6
  Project-URL: Homepage, https://pulpproject.org
@@ -1,6 +1,6 @@
1
1
  pulp_python/__init__.py,sha256=GIuTLoBTc-07dSLJUh8xrZPRz8x-jJ61pfR0J1IjnzI,65
2
2
  pulp_python/pytest_plugin.py,sha256=LNnLjOkeEu2X4gJi614bHVmbsHyEwooHYIeecr96Qy4,8606
3
- pulp_python/app/__init__.py,sha256=BJ8lPp1YfHN-COJvkt8NqSmKQpFyFyTnmtJ-nUF_wCY,2490
3
+ pulp_python/app/__init__.py,sha256=apCXN6djyith2YIcU2ObCVZQ07CSy6aw0XRNl2fnPIE,2490
4
4
  pulp_python/app/global_access_conditions.py,sha256=MZJtyoVsr-4hRaty6mKDqh3caOHd5UKJjEWLV2crOLs,1080
5
5
  pulp_python/app/modelresource.py,sha256=4SFAdqk6lozi_cZz4uqDIqhqPAZF-7l5jJwPn-xGZFs,1249
6
6
  pulp_python/app/models.py,sha256=VVyr8LjAtHeHvY6klFeokwHNnY90qUuMchalm-2Gtjk,14056
@@ -41,7 +41,7 @@ pulp_python/app/pypi/views.py,sha256=CmYBgrXBBSNcF0FSFWvOILJrexOUvH2M2FPO-Jiea6c
41
41
  pulp_python/app/tasks/__init__.py,sha256=lTFpVvpDKbqv9RC0b2RYU8Bo6svDjrA-djt16pADFr8,284
42
42
  pulp_python/app/tasks/publish.py,sha256=EMAfOZH8EFB9A-rzuxjrQG5FnvSXBVGT7dHQGCAUtrM,4334
43
43
  pulp_python/app/tasks/repair.py,sha256=5InzdbjW8y3AC4Vj2PsNLm3wGGTr8D3LcfPw_WA2Fks,12257
44
- pulp_python/app/tasks/sync.py,sha256=LqGQsiSbOQl05H9e7PC830aaLDuQXS1Ql1GiwfrO1Qc,12866
44
+ pulp_python/app/tasks/sync.py,sha256=4IcAA0z2ewONfWZkx3srrvfV_-7jcQCTdWhUXCGn808,12875
45
45
  pulp_python/app/tasks/upload.py,sha256=Pclsh6co5hBO6wdxZbGKBUSBV643nd9c2RXQO2Nkdik,5698
46
46
  pulp_python/app/tasks/vulnerability_report.py,sha256=0cyxNb4048HFUdUlGBA6wYsg-hEMjSfE8mtw05Ct9BQ,1126
47
47
  pulp_python/app/webserver_snippets/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -52,7 +52,7 @@ pulp_python/tests/functional/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NM
52
52
  pulp_python/tests/functional/constants.py,sha256=4e_zssE9G1bSNNJxYo7VgwvojUL_NocG5mUH996KBJs,13969
53
53
  pulp_python/tests/functional/utils.py,sha256=GWnXrsQGZd0Ngewa_9yce58Qc3z7FbrlRvqao_8ZML0,5901
54
54
  pulp_python/tests/functional/api/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
55
- pulp_python/tests/functional/api/test_attestations.py,sha256=cyZl4jCL-Q5Qu7XpxLc5_YmCzyc1Ctfl1IvSJ6YPQQU,8640
55
+ pulp_python/tests/functional/api/test_attestations.py,sha256=tvRSsHyQVkoAp-Myoo_Y_7gz-HyNR8EA8G1yvik3dEg,10358
56
56
  pulp_python/tests/functional/api/test_auto_publish.py,sha256=uCIt4LsO61oMk3bDs3LMQDJI8zkKqvY0b1uX16bTxzM,1747
57
57
  pulp_python/tests/functional/api/test_consume_content.py,sha256=-7b6KOrIT3NLSUafeu1tzXEXRPddDbS5VeMHxMIy2n8,999
58
58
  pulp_python/tests/functional/api/test_crud_content_unit.py,sha256=Pwjv3ytSfqBuoemuhJNIOEWdwzurPVN1XO3kDRlLFqY,8757
@@ -62,7 +62,7 @@ pulp_python/tests/functional/api/test_domains.py,sha256=uEA7dIBXaXah3WQ6g6xSIjdX
62
62
  pulp_python/tests/functional/api/test_download_content.py,sha256=5IuaHXyLakPkjm5sLTxtTl7Dq0yl7N36HpObnIa0Sks,4950
63
63
  pulp_python/tests/functional/api/test_export_import.py,sha256=rHns9wdaeP-vtfW_qoGHU9EVuJ4YuWE0-rjl_8otAgU,4530
64
64
  pulp_python/tests/functional/api/test_full_mirror.py,sha256=eU5HzgBBFOnX1q4m8ELx-t-I3U4TWXL-LNrlc2BcWVc,12045
65
- pulp_python/tests/functional/api/test_pypi_apis.py,sha256=mhST0GV-uDrVPsBWYRGaJx1pp9htzbYiUGuIGOI0s_s,13218
65
+ pulp_python/tests/functional/api/test_pypi_apis.py,sha256=TyehTS_Jo83yAb1d0l4XOWUJ-g4380UraCsKvhF_FWo,13224
66
66
  pulp_python/tests/functional/api/test_pypi_simple_api.py,sha256=tOUl8WXgJkMoxGyLbA-WorCxIRKfGWM-27_dK_Jc0Q4,7171
67
67
  pulp_python/tests/functional/api/test_rbac.py,sha256=-xNWqvKKU-v1uC6tCRGBK0aWaff25K9C-AfzQkdHhhI,10513
68
68
  pulp_python/tests/functional/api/test_repair.py,sha256=4FR7jx_LA2K-pnRJXKkhq-1uUoWXST1leZ9XdyhGM2U,12909
@@ -73,9 +73,9 @@ pulp_python/tests/functional/assets/shelf-reader-0.1.tar.gz.publish.attestation,
73
73
  pulp_python/tests/functional/assets/shelf_reader-0.1-py2-none-any.whl.publish.attestation,sha256=muTQ8dqYSSdx76DlaPjB1REcNIS-aak-Na0TkASxu8M,10426
74
74
  pulp_python/tests/unit/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
75
75
  pulp_python/tests/unit/test_models.py,sha256=TBI0yKsrdbnJSPeBFfxSqhXK7zaNvR6qg5JehGH3Pds,229
76
- pulp_python-3.27.5.dist-info/licenses/LICENSE,sha256=2ylvL381vKOhdO-w6zkrOxe9lLNBhRQpo9_0EbHC_HM,18046
77
- pulp_python-3.27.5.dist-info/METADATA,sha256=L2IkhGBoAT1cdQ4yLZiOvrQ1IUuBASm4TJWbgIHlAJU,1743
78
- pulp_python-3.27.5.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
79
- pulp_python-3.27.5.dist-info/entry_points.txt,sha256=HvqLEXjw_dS5jqAwnE5JiRZFE6f-y5SRtitKLPml2To,115
80
- pulp_python-3.27.5.dist-info/top_level.txt,sha256=X0hXgXc_bpbiKqVrkt8jD5_QEiQviKbHDwveQcOcJjo,12
81
- pulp_python-3.27.5.dist-info/RECORD,,
76
+ pulp_python-3.27.6.dist-info/licenses/LICENSE,sha256=2ylvL381vKOhdO-w6zkrOxe9lLNBhRQpo9_0EbHC_HM,18046
77
+ pulp_python-3.27.6.dist-info/METADATA,sha256=zscAK-6TynP7UoRHvGn-qkYfhlcw9_AXvPLWZo3AHog,1743
78
+ pulp_python-3.27.6.dist-info/WHEEL,sha256=K260EYznzXsJYBQGqmI8VTxEdiZYNvDZwW9cBh9-_MA,91
79
+ pulp_python-3.27.6.dist-info/entry_points.txt,sha256=HvqLEXjw_dS5jqAwnE5JiRZFE6f-y5SRtitKLPml2To,115
80
+ pulp_python-3.27.6.dist-info/top_level.txt,sha256=X0hXgXc_bpbiKqVrkt8jD5_QEiQviKbHDwveQcOcJjo,12
81
+ pulp_python-3.27.6.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (82.0.1)
2
+ Generator: setuptools (83.0.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5