Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: canonical/data-platform-workflows
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: b17aee81ea6967239e49be95bb859bd24b867240
Choose a base ref
..
head repository: canonical/data-platform-workflows
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 77790f088e7a76eade505b0979550345befa4505
Choose a head ref
Showing with 8 additions and 10 deletions.
  1. +0 −9 .github/workflows/build_charm.yaml
  2. +8 −1 python/cli/data_platform_workflows_cli/craft_tools/collect_platforms.py
9 changes: 0 additions & 9 deletions .github/workflows/build_charm.yaml
Original file line number Diff line number Diff line change
@@ -87,12 +87,6 @@ jobs:
runs-on: ${{ matrix.platform.runner }}
timeout-minutes: 120
steps:
- name: (GitHub-hosted ARM runner) Install libpq-dev
if: ${{ matrix.platform.runner == 'Ubuntu_ARM64_4C_16G_02' }}
# Needed for `charmcraftcache` to resolve dependencies (for postgresql charms with psycopg2)
run: |
sudo apt-get update
sudo apt-get install libpq-dev -y
- name: Get workflow version
id: workflow-version
uses: canonical/get-workflow-version-action@v1
@@ -128,9 +122,6 @@ jobs:
sudo iptables -P FORWARD ACCEPT
sudo snap install charmcraft --classic ${{ steps.charmcraft-snap-version.outputs.install_flag }}
pipx install poetry
pipx inject poetry poetry-plugin-export
pipx install charmcraftcache
- run: snap list
- name: Pack charm
Original file line number Diff line number Diff line change
@@ -73,8 +73,15 @@ def collect(craft_: craft.Craft):
platforms.append({"name": platform, "runner": RUNNERS[architecture]})
elif yaml_data["base"] == "core22":
for entry in yaml_data["architectures"]:
# Example: ["amd64"]
platforms_ = entry["build-on"]
if not (isinstance(platforms_, list) and len(platforms_) == 1):
raise ValueError(
"Expected snapcraft.yaml 'build-on' value with type 'list' and length 1, "
f"got: {repr(platforms_)}"
)
# Example: "amd64"
platform = entry["build-on"]
platform = platforms_[0]
architecture = craft.Architecture(platform)
platforms.append({"name": platform, "runner": RUNNERS[architecture]})
else: