Skip to content

Commit 017b175

Browse files
committed
Raise upperbound for pkginfo requirement
1 parent 40c7af9 commit 017b175

File tree

4 files changed

+18
-3
lines changed

4 files changed

+18
-3
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Ensure uploading packages with metadata spec 2.4 is supported.

pulp_python/tests/functional/api/test_crud_content_unit.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,3 +242,16 @@ def test_upload_metadata_23_spec(python_content_factory):
242242
content = python_content_factory(filename, url=package.url)
243243
assert content.metadata_version == "2.3"
244244
break
245+
246+
247+
@pytest.mark.parallel
248+
def test_upload_metadata_24_spec(python_content_factory):
249+
"""Test that packages using metadata spec 2.4 can be uploaded to pulp."""
250+
filename = "urllib3-2.3.0-py3-none-any.whl"
251+
with PyPISimple() as client:
252+
page = client.get_project_page("urllib3")
253+
for package in page.packages:
254+
if package.filename == filename:
255+
content = python_content_factory(filename, url=package.url)
256+
assert content.metadata_version == "2.4"
257+
break

pulp_python/tests/functional/api/test_pypi_apis.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,8 @@ def test_twine_upload(self):
167167
repo, distro = self._create_empty_repo_and_distribution()
168168
url = urljoin(PYPI_HOST, distro.base_path + "/legacy/")
169169
username, password = "admin", "password"
170-
subprocess.run(
170+
# Testing what the error is
171+
output = subprocess.run(
171172
(
172173
"twine",
173174
"upload",
@@ -180,8 +181,8 @@ def test_twine_upload(self):
180181
password,
181182
),
182183
capture_output=True,
183-
check=True,
184184
)
185+
print(output.stderr)
185186
tasks = task_api.list(reserved_resources_record=[repo.pulp_href]).results
186187
for task in reversed(tasks):
187188
t = monitor_task(task.pulp_href)

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
pulpcore>=3.28,<3.55
2-
pkginfo>=1.10.0,<1.12.0 # Twine has <1.11 in their requirements
2+
pkginfo>=1.10.0,<1.13.0
33
bandersnatch>=6.1,<6.2
44
pypi-simple>=0.9.0,<1.0.0

0 commit comments

Comments
 (0)