From 06f92747ab6748ca5db2071fb6dc6bee3c60673d Mon Sep 17 00:00:00 2001 From: Alex Pyrgiotis Date: Wed, 14 Dec 2022 15:16:53 +0200 Subject: [PATCH] ci: Fix the failing run-lint step Fix the failing run-lint test by switching to Debian Bookworm for this step, and installing Poetry 1.2.2 from the official repos. This way, we circumvent a bug [1] in Poetry 1.3 (released on PyPI) and we greatly simplify this step [2]. [1]: https://github.com/python-poetry/poetry/issues/7184 [2]: https://github.com/freedomofpress/dangerzone/issues/292#issuecomment-1351368122 --- .circleci/config.yml | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index cace615..6715b3e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -70,25 +70,21 @@ aliases: jobs: run-lint: docker: - - image: debian:bullseye + - image: debian:bookworm resource_class: small steps: - checkout - run: name: Install dev. dependencies + # Install only the necessary packages to run our linters. command: | export DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true apt-get update - apt-get install -y make python3 python3-pip python3-venv - python3 -m venv .venv - source .venv/bin/activate - pip install poetry - poetry install # FIXME --dev-only once poetry 1.2.0 is out https://github.com/python-poetry/poetry/issues/2572 + apt-get install -y make python3 python3-poetry --no-install-recommends + poetry install --only lint - run: name: Run linters to enforce code style - command: | - source .venv/bin/activate - make lint + command: poetry run make lint build-container-image: working_directory: /app