From b425bc5f67581795638183f485bd115027064a10 Mon Sep 17 00:00:00 2001 From: Dmitry Ratushnyy <132273757+dmitry-ratushnyy@users.noreply.github.com> Date: Wed, 3 Jan 2024 17:55:12 +0100 Subject: [PATCH 1/2] [DPE-3216] Bump workflow version for CI to version 8 (#321) ## Issue We need to keep our github workflows up-to date with data platform ones ## Solution Update the workflows to latest version ## Related issue https://warthogs.atlassian.net/browse/DPE-3216 --- .github/workflows/ci.yaml | 2 +- .github/workflows/release.yaml | 4 ++-- .github/workflows/sync_issue_to_jira.yaml | 2 +- tox.ini | 20 ++++++++++---------- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index be9592ac7..cc2496ffb 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -67,7 +67,7 @@ jobs: build: name: Build charms - uses: canonical/data-platform-workflows/.github/workflows/build_charms_with_cache.yaml@v7 + uses: canonical/data-platform-workflows/.github/workflows/build_charms_with_cache.yaml@v8 integration-test: strategy: diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index f8722f84c..06fc80ee8 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -17,7 +17,7 @@ jobs: build: name: Build charm - uses: canonical/data-platform-workflows/.github/workflows/build_charm_without_cache.yaml@v5.1.2 + uses: canonical/data-platform-workflows/.github/workflows/build_charm_without_cache.yaml@v8 with: charmcraft-snap-channel: "latest/stable" @@ -26,7 +26,7 @@ jobs: needs: - ci-tests - build - uses: canonical/data-platform-workflows/.github/workflows/release_charm.yaml@v5 + uses: canonical/data-platform-workflows/.github/workflows/release_charm.yaml@v8 with: channel: 6/edge artifact-name: ${{ needs.build.outputs.artifact-name }} diff --git a/.github/workflows/sync_issue_to_jira.yaml b/.github/workflows/sync_issue_to_jira.yaml index 4221f69ef..ab8fd5155 100644 --- a/.github/workflows/sync_issue_to_jira.yaml +++ b/.github/workflows/sync_issue_to_jira.yaml @@ -9,7 +9,7 @@ on: jobs: sync: name: Sync GitHub issue to Jira - uses: canonical/data-platform-workflows/.github/workflows/sync_issue_to_jira.yaml@v2 + uses: canonical/data-platform-workflows/.github/workflows/sync_issue_to_jira.yaml@v8 with: jira-base-url: https://warthogs.atlassian.net jira-project-key: DPE diff --git a/tox.ini b/tox.ini index 3cf190a65..34c97d6e5 100644 --- a/tox.ini +++ b/tox.ini @@ -78,7 +78,7 @@ deps = pytest-operator protobuf==3.20 # temporary fix until new libjuju is released pytest-mock - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -v --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/test_charm.py @@ -94,7 +94,7 @@ deps = pytest-mock pytest-operator protobuf==3.20 # temporary fix until new libjuju is released - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -vvv --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/ha_tests/test_ha.py @@ -110,7 +110,7 @@ deps = pytest-mock pytest-operator protobuf==3.20 # temporary fix until new libjuju is released - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -v --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/relation_tests/new_relations/test_charm_relations.py @@ -126,7 +126,7 @@ deps = pytest-mock pytest-operator protobuf==3.20 # temporary fix until new libjuju is released - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -v --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/relation_tests/legacy_relations/test_charm_legacy_relations.py @@ -142,7 +142,7 @@ deps = pytest-mock pytest-operator protobuf==3.20 # temporary fix until new libjuju is released - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -v --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/tls_tests/test_tls.py @@ -163,7 +163,7 @@ deps = pytest-mock pytest-operator protobuf==3.20 # temporary fix until new libjuju is released - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -v --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/backup_tests/test_backups.py @@ -179,7 +179,7 @@ deps = pytest-mock pytest-operator protobuf==3.20 # temporary fix until new libjuju is released - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -v --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/metrics_tests/test_metrics.py @@ -195,7 +195,7 @@ deps = pytest-mock pytest-operator protobuf==3.20 # temporary fix until new libjuju is released - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -v --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/sharding_tests/test_sharding.py @@ -211,7 +211,7 @@ deps = pytest-mock pytest-operator protobuf==3.20 # temporary fix until new libjuju is released - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -v --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/sharding_tests/test_sharding_relations.py @@ -228,7 +228,7 @@ deps = pytest-mock pytest-operator protobuf==3.20 # temporary fix until new libjuju is released - git+https://github.com/canonical/data-platform-workflows@v5.1.2\#subdirectory=python/pytest_plugins/pytest_operator_cache + git+https://github.com/canonical/data-platform-workflows@v8\#subdirectory=python/pytest_plugins/pytest_operator_cache -r {tox_root}/requirements.txt commands = pytest -v --tb native --log-cli-level=INFO -s --durations=0 {posargs} {[vars]tests_path}/integration/ From 1f2f1dcab16d1bf1b9b353c5c9fb67bda7fbca23 Mon Sep 17 00:00:00 2001 From: Mia Altieri <32723809+MiaAltieri@users.noreply.github.com> Date: Thu, 4 Jan 2024 06:44:53 -0800 Subject: [PATCH 2/2] LIBPATCHES are too advanced on some files (#323) The publishing workflows are failing [on GitHub](https://github.com/canonical/mongodb-operator/actions/runs/7197560677/job/19607662510) this was caused by 1. the first time publishing failed due to unrelated issue 2. then the libpatch was bumped on subsequent PRs as that is standard practice 3. then publish libs fails because of 2. --- lib/charms/mongodb/v0/config_server_interface.py | 2 +- lib/charms/mongodb/v1/shards_interface.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/charms/mongodb/v0/config_server_interface.py b/lib/charms/mongodb/v0/config_server_interface.py index b1dbb145b..eeb1ee299 100644 --- a/lib/charms/mongodb/v0/config_server_interface.py +++ b/lib/charms/mongodb/v0/config_server_interface.py @@ -35,7 +35,7 @@ # Increment this PATCH version before using `charmcraft publish-lib` or reset # to 0 if you are raising the major API version -LIBPATCH = 6 +LIBPATCH = 1 class ClusterProvider(Object): diff --git a/lib/charms/mongodb/v1/shards_interface.py b/lib/charms/mongodb/v1/shards_interface.py index 8f1244fed..da7cc8320 100644 --- a/lib/charms/mongodb/v1/shards_interface.py +++ b/lib/charms/mongodb/v1/shards_interface.py @@ -51,7 +51,7 @@ # Increment this PATCH version before using `charmcraft publish-lib` or reset # to 0 if you are raising the major API version -LIBPATCH = 4 +LIBPATCH = 2 KEYFILE_KEY = "key-file" HOSTS_KEY = "host" OPERATOR_PASSWORD_KEY = MongoDBUser.get_password_key_name_for_user(OperatorUser.get_username())