[maintenance] Upgrade the use of `pip-tools` to leverage its modern features
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Python
- Sterne
- 20.6k
- Forks
- 3.3k
- PR-Merge-Kennzahlen
- PR-Kennzahlen ausstehend
Beschreibung
Feature
$sbj. pip-tools now supports config files (through .pip-tools.toml or pyproject.toml — https://pip-tools.readthedocs.io/en/stable/#configuration). It also supports extracting the build requirements (https://pip-tools.readthedocs.io/en/stable/#maximizing-reproducibility).
Pitch
I saw a couple of pip-tools-managed files in the repo but no documentation on invoking pip-compile or a wrapper script for updating the pins. Having a config file would help with keeping the settings consistent if somebody calls it w/o all the expected args. Here's a config example I tend to use: https://github.com/cherrypy/cheroot/blob/1ff20b1/.pip-tools.toml.
As for the build deps, using one of --build-deps-for [editable|sdist|wheel], --all-build-deps or --only-build-deps can help you get rid of https://github.com/python/mypy/blob/fe15ee6/build-requirements.txt#L1 and https://github.com/python/mypy/blob/fe15ee6/mypy-requirements.txt#L1-L2 which relies on people having to remember to keep things in sync across to copies of deps lists.
cc @hauntsaninja since you were the last to touch build-requirements.txt and @AlexWaygood as you wrote the following in your commit message last changing mypy-requirements.txt:
(Can't say I fully understand why we have to have
this pin in three places :)
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne damit, die in der Issue genannten pip-tools-Konfiguration sowie die Dateien build-requirements.txt und mypy-requirements.txt zu lesen, und vergleiche sie anschließend mit der Konfigurations- und Build-Abhängigkeitsdokumentation von pip-tools. Ermittle, wie Abhängigkeits-Pins derzeit gepflegt werden und wie die Ausführung dokumentiert ist. Als abgeschlossen gilt die Arbeit, wenn die pip-tools-Einstellungen konsistent sind, doppelte Abhängigkeitslisten reduziert wurden und Update-Befehle dokumentiert sind.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- python
- Bereich
- build-system, tooling
- Issue-Typ
- Refactoring
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 35/100