From 3efab6a56efadc7808093ff2555d27b380d044fb Mon Sep 17 00:00:00 2001 From: Sorin Sbarnea Date: Mon, 6 Nov 2023 13:51:25 +0000 Subject: [PATCH] Preinstall cython to avoid pyyaml installation errors Related: https://github.com/yaml/pyyaml/issues/601 --- _build/requirements.txt | 4 ++++ _build/test-setup.sh | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/_build/requirements.txt b/_build/requirements.txt index cd2cebb..6c22030 100644 --- a/_build/requirements.txt +++ b/_build/requirements.txt @@ -1,3 +1,7 @@ +# prepare: +# see: https://github.com/yaml/pyyaml/issues/601 +cython>=3.0.5; python_version >= "3.12" +# ordered: ansible-pylibssh==1.1.0 ansible-runner==2.3.4 ansible-lint[lock]==6.21.1 diff --git a/_build/test-setup.sh b/_build/test-setup.sh index 7010401..7693088 100755 --- a/_build/test-setup.sh +++ b/_build/test-setup.sh @@ -51,7 +51,8 @@ if [[ -f "/usr/bin/apt-get" ]]; then INSTALL=0 # qemu-user-static is required by podman on arm64 # python3-dev is needed for headers as some packages might need to compile - DEBS=(curl git python3-pip python3-venv qemu-user-static jq gh) + # python3-cython is needed to headers to compile pyyaml 6.0, see https://github.com/yaml/pyyaml/issues/601 + DEBS=(curl git python3-pip python3-venv python3-cython qemu-user-static jq gh) for DEB in "${DEBS[@]}"; do [[ "$(dpkg-query --show --showformat='${db:Status-Status}\n' \ "${DEB}" || true)" != 'installed' ]] && INSTALL=1