Skip to content

Commit

Permalink
Add bounds to all dependencies
Browse files Browse the repository at this point in the history
[noissue]
  • Loading branch information
mdellweg committed Feb 5, 2024
1 parent 2b94cb2 commit a07ccb2
Show file tree
Hide file tree
Showing 24 changed files with 34 additions and 25 deletions.
3 changes: 3 additions & 0 deletions lower_bounds_constraints.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@ PyYAML==5.3
requests==2.24.0
schema==0.7.5
toml==0.10.2
pygments==2.17.2
importlib_metadata==4.8.0
importlib_resources==5.4.0
2 changes: 1 addition & 1 deletion pulp-glue/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ classifiers = [
dependencies = [
"packaging>=20.0,<24",
"requests>=2.24.0,<2.32",
"importlib_resources>=5.4,<6.2;python_version<'3.9'",
"importlib_resources>=5.4.0,<6.2;python_version<'3.9'",
]

[project.urls]
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@ dependencies = [
"PyYAML>=5.3,<6.1",
"schema>=0.7.5,<0.8",
"toml>=0.10.2,<0.11",
"importlib_metadata>=4.8,<7.1;python_version<'3.10'",
"importlib_metadata>=4.8.0,<7.1;python_version<'3.10'",
]

[project.optional-dependencies]
pygments = ["pygments"]
pygments = ["pygments>=2.17.2,<2.18"]
shell = ["click-shell~=2.1"]

[project.urls]
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

import pytest

pytest_plugins = "pytest_pulp_cli"
pytest_plugins = ("pytest_pulp_cli",)


@pytest.fixture
Expand Down
6 changes: 3 additions & 3 deletions tests/scripts/pulp_ansible/test_content.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ trap cleanup EXIT

pulp orphan cleanup --protection-time 0

if pulp debug has-plugin --name "ansible" --min-version "0.15.0"
if pulp debug has-plugin --name "ansible" --specifier ">=0.15.0"
then
gpg --output pulp_pubkey.key --armor --export "pulp-fixture-signing-key"
expect_succ pulp ansible repository create --name "cli_test_ansible_repository_verify" --gpgkey @pulp_pubkey.key
Expand Down Expand Up @@ -50,7 +50,7 @@ content2_href="$(echo "$OUTPUT" | jq -r .[0].pulp_href)"
expect_succ pulp ansible content --type "role" show --href "$content2_href"

# Test ansible signature upload
if pulp debug has-plugin --name "ansible" --min-version "0.13.0"
if pulp debug has-plugin --name "ansible" --specifier ">=0.13.0"
then
expect_succ pulp ansible content --type "signature" list
tar --extract --file="ansible-posix-1.3.0.tar.gz" "MANIFEST.json"
Expand All @@ -72,7 +72,7 @@ expect_succ pulp ansible repository content --type "role" add --repository "cli_
expect_succ pulp ansible repository content --type "role" list --repository "cli_test_ansible_repository" --version 2
test "$(echo "$OUTPUT" | jq -r length)" -eq "1"

if pulp debug has-plugin --name "core" --min-version "3.11.0"
if pulp debug has-plugin --name "core" --specifier ">=3.11.0"
then
expect_succ pulp ansible repository content list --repository "cli_test_ansible_repository" --version 2 --all-types
test "$(echo "$OUTPUT" | jq -r length)" -eq "2"
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_ansible/test_sign.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "ansible" --min-version "0.12.0" || exit 23
pulp debug has-plugin --name "ansible" --specifier ">=0.12.0" || exit 23
[ "$(pulp signing-service list --name "sign_ansible" | jq 'length')" = "1" ] || exit 23

cleanup() {
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_container/test_distribution.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ expect_succ pulp container distribution list
expect_succ pulp container distribution show --distribution "cli_test_container_distro"

# see https://pulp.plan.io/issues/9497
if pulp debug has-plugin --name "container" --min-version "2.10.0"
if pulp debug has-plugin --name "container" --specifier ">=2.10.0"

then
expect_succ pulp container distribution update --distribution "cli_test_container_distro" --version 0
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_container/test_role.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "container" --min-version "2.11.0" || exit 23
pulp debug has-plugin --name "container" --specifier ">=2.11.0" || exit 23

USERPASS="Yeech6ba"

Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_file/test_acs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "file" --min-version "1.10.0" || exit 23
pulp debug has-plugin --name "file" --specifier ">=1.10.0" || exit 23

acs_remote="cli_test_file_acs_remote"
acs="cli_test_acs"
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_file/test_distribution.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ expect_succ pulp file distribution update \
--publication "$PUBLICATION_HREF" \
--content-guard ""

if pulp debug has-plugin --name "file" --min-version "1.7.0"
if pulp debug has-plugin --name "file" --specifier ">=1.7.0"
then
expect_succ pulp file distribution update \
--distribution "cli_test_file_distro" \
Expand Down
2 changes: 2 additions & 0 deletions tests/scripts/pulp_file/test_label.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "file" --specifier ">=1.6.0" || exit 23

cleanup() {
pulp file repository destroy --name "cli_test_file_repo" || true
}
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_file/test_publication.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ PUBLICATION_HREF="$(echo "$OUTPUT" | jq -r .pulp_href)"
expect_succ pulp file publication destroy --href "$PUBLICATION_HREF"
expect_succ pulp file publication create --repository "cli_test_file_repository" --version 0
PUBLICATION_HREF="$(echo "$OUTPUT" | jq -r .pulp_href)"
if pulp debug has-plugin --name "core" --min-version "3.20.0"
if pulp debug has-plugin --name "core" --specifier ">=3.20.0"
then
expect_succ pulp file publication list --repository "cli_test_file_repository"
test "$(echo "$OUTPUT" | jq -r length)" -eq 1
Expand Down
4 changes: 2 additions & 2 deletions tests/scripts/pulp_file/test_repository.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ test "$(echo "$OUTPUT" | jq -r '.|length')" != "0"
expect_succ pulp file repository task list --repository "cli_test_file_repo"
test "$(echo "$OUTPUT" | jq -r '.|length')" = "6"

if pulp debug has-plugin --name "file" --min-version "1.7.0"
if pulp debug has-plugin --name "file" --specifier ">=1.7.0"
then
expect_succ pulp file repository update --repository "cli_test_file_repo" --manifest "manifest.csv"

if pulp debug has-plugin --name "file" --min-version "1.12.0"
if pulp debug has-plugin --name "file" --specifier ">=1.12.0"
then
expect_succ pulp file repository update --repository "cli_test_file_repo" --manifest ""
expect_succ pulp file repository show --repository "cli_test_file_repo"
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_file/test_role.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "file" --min-version "1.11.0" || exit 23
pulp debug has-plugin --name "file" --specifier ">=1.11.0" || exit 23

USERPASS="Yeech6ba"

Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_rpm/test_acs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "rpm" --min-version "3.18.0" || exit 23
pulp debug has-plugin --name "rpm" --specifier ">=3.18.0" || exit 23

# This container seems to have issues with the compression format of the fixture.
pulp debug has-plugin --name "rpm" --specifier "==3.20.0" && pulp debug has-plugin --name "core" --specifier "==3.23.21" && exit 23
Expand Down
2 changes: 2 additions & 0 deletions tests/scripts/pulp_rpm/test_comps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "rpm" || exit 23

cleanup() {
pulp rpm repository destroy --name "cli_test_rpm_repository" || true
}
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_rpm/test_rpm_sync_publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ expect_succ pulp rpm repository sync --repository "cli_test_rpm_repository" --sy
expect_succ pulp rpm repository sync --repository "cli_test_rpm_repository" --sync-policy mirror_content_only
expect_fail pulp rpm repository sync --repository "cli_test_rpm_repository" --sync-policy foobar

if pulp debug has-plugin --name "rpm" --min-version "3.25.0.dev"
if pulp debug has-plugin --name "rpm" --specifier ">=3.25.0.dev"
then
expect_succ pulp rpm publication create --repository "cli_test_rpm_repository" --checksum-type sha512
expect_fail pulp rpm publication create --repository "cli_test_rpm_repository" --checksum-type sha1
Expand Down
2 changes: 2 additions & 0 deletions tests/scripts/pulp_rpm/test_uln_remote.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "rpm" || exit 23

# Set USERNAME, USERPASS, and ULN_REMOTE_URL for tests to work.

USERNAME="user"
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulpcore/test_cert_guards.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "certguard" --min-version "1.4.0" || exit 23
pulp debug has-plugin --name "certguard" --specifier ">=1.4.0" || exit 23

cleanup() {
pulp content-guard x509 destroy --name "cli_test_x509_guard" || true
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulpcore/test_group_permissions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "core" --max-version "3.20-dev" || exit 23
pulp debug has-plugin --name "core" --specifier "<3.20-dev" || exit 23

cleanup() {
pulp group destroy --name "cli_test_group" || true
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulpcore/test_repository_reclaim_space.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "core" --min-version "3.19.0" || exit 23
pulp debug has-plugin --name "core" --specifier ">=3.19.0" || exit 23
pulp debug has-plugin --name "file" || exit 23

cleanup() {
Expand Down
4 changes: 2 additions & 2 deletions tests/scripts/pulpcore/test_rhsm_cert_guards.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "certguard" --min-version "1.4.0" || exit 23
pulp debug has-plugin --name "certguard" --specifier ">=1.4.0" || exit 23

# Seems like the rhsm module is not installed on older oci_images
pulp debug has-plugin --name "core" --min-version "3.22" || exit 23
pulp debug has-plugin --name "core" --specifier ">=3.22" || exit 23

cleanup() {
pulp content-guard rhsm destroy --name "cli_test_rhsm_guard" || true
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulpcore/test_upstream_pulp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(dirname "$(realpath "$0")")")"/config.source

pulp debug has-plugin --name "core" --min-version "3.23.0" || exit 23
pulp debug has-plugin --name "core" --specifier ">=3.23.0" || exit 23

cleanup() {
pulp upstream-pulp destroy --upstream-pulp "cli_test_upstream_pulp" || true
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/test_debug.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# shellcheck source=tests/scripts/config.source
. "$(dirname "$(realpath "$0")")"/config.source

expect_succ pulp debug has-plugin --name "core" --max-version "4.0"
expect_succ pulp debug has-plugin --name "core" --specifier "<4.0"
expect_succ pulp debug openapi spec
expect_succ pulp debug openapi operation-ids
expect_succ pulp debug openapi operation --id tasks_list

0 comments on commit a07ccb2

Please sign in to comment.