Skip to content

fix("schedule-issuebot" CI job): Conform with PEP 668 to work on Alpine 3.19

javulticat requested to merge javulticat/fdroiddata:fix-schedule-issuebot into master

Description

Hi there, I noticed your schedule-issuebot scheduled CI job hasn't been doing so hot lately 🤢... As you can see in prior link, the last time the job ran successfully was on December 7th. This is because, also on December 7th, Alpine 3.19 was released, so that run was the last time the job ran on Alpine 3.18.

What's so different about Alpine 3.19?

The release notes for Alpine 3.19 state: Python’s package directory is now marked as externally managed, which means that pip can no longer install to system directory which is managed by apk. This is because, starting with Alpine 3.19, Alpine has decided to join most other major Linux distros in conforming to PEP 668, which enables and encourages distros to prevent users from engaging in the potentially dangerous practice of using a Python package manager (such as pip) to install Python packages at the system level, and forces them to instead use the long-encouraged practice of creating isolated virtual environments in which to install Python packages.

This MR simply follows the practice recommended by PEP 668: it creates and initializes a Python virtual environment before using it to install Python dependencies and run ./tools/schedule-issuebot.py, replacing the previous config that attempts to install Python dependencies at the system level (which is what has been causing the failures since Alpine 3.19 came out). See here for proof that it works: in my fork, I forced the job to run immediately (without the schedule) while using this new CI configuration, and it ran successfully.

Hope this helps!

CC

@eighthave and @proletarius101 (who git blame shows are the most recent editors of the schedule-issuebot CI job)

Merge request reports