actions / actions/setup-python
Add "Externally Managed Environments" support to block global package installations via pip
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- TypeScript
- Estrellas
- 2.2k
- Forks
- 739
- Merge medio
- 6 d 18 h
- PR fusionados (30 d)
- 1
Descripción
Description:
To prevent system package breakage, many Linux distributions are now restricting pip install to virtual environments or uv environments (something private either way). In self-hosted environments, especially when using ephemeral runners, the hosted tools cache functionality is critical for scaling.
The current methodology allows a pip install to install directly to the cached directory for a given Python after installation, which leads to potentially broken dependency trees and all other kinds of errors if developers are not careful with their package installs. It can also lead to weird race conditions in the same way.
I propose a new input for actions/setup-python that creates the EXTERNALLY-MANAGED file right before a version of Python is marked as available (e.g. creation of the x64.complete file) that would block global pip installs.
Justification:
Did all of this in the above. Didn't read the template first.
Are you willing to submit a PR?
Absolutely. This is more of a RFC to gauge the level of interest here.
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Línea de trabajo
Empieza leyendo la ruta de setup-python tool-cache que marca como disponible una versión de Python instalada y, después, revisa la especificación enlazada sobre entornos gestionados externamente. Determina cómo debe crearse el marcador antes de registrar la disponibilidad y qué pruebas existentes cubren las instalaciones de Python almacenadas en caché. Se considera terminado cuando las instalaciones globales de pip están bloqueadas para el intérprete almacenado en caché sin interrumpir los flujos de trabajo compatibles de virtual-environment o uv.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- python, typescript
- Área
- ci-cd, devops, tooling
- Tipo de issue
- Nueva funcionalidad
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 35/100