Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I don't think it's reasonable to expect that most python installs use pip





Why not?

I'm not sure what @LtWorf means, exactly, but one reason I can think of is that on Linux (Gentoo & Debian at least), the system package managers are not putting pip in place by default with python itself, the way they used to. The rationale, I believe, is to steer users towards using the system package manager or only doing ~/.local style things.

EDIT: So, you get threads like this https://stackoverflow.com/questions/65651040/what-is-the-rec... and so on


Presumably there’s a distro maintained python3-cgi package to install then which handles the need


Because it's much easier to use apt and install the module system-wide, and then I don't need to mess around with venv, requirements.txt, and there's someone that will fix any CVEs or malicious backdoors that get found out, automatically. Unlike what happens with venv.

It's much easier until you run into a package that doesn't have a .deb for it, like, well, CGI?

That is very much a self-inflicted wound, though. If you insist on not using the standard packaging solution for the language, you have to own the complications of that.


If you do insist on using pip, you will often find that it works very poorly or not at all if you are using an old version of either Python or some Python module. This is another aspect of the social backward compatibility problems in the current Python community.

https://packages.debian.org/sid/python3-legacy-cgi

Python has no standard packaging. They even deprecated and removed distutils (another terrible idea that caused a lot of busywork). The only way that python supports packages is via 3rd party external solutions.


Wheels are the standard Python packaging.

Source?

PEP 427

Describing a format and saying it's the standard are not one and the same.

Yeah, the distutils clusterfuck is another excellent reason someone might "insist on not using the standard packaging solution for the language": it's specifically and only the packages that did use the standard packaging solution for the language, distutils, that got broken when distutils was removed from the standard library.

I mean, I understand the desire to remove distutils. It sucked. It was the least Pythonic package in the whole Python standard library. But removing it was even worse, because it means you can't use old versions of most Python libraries with recent versions of Python.


You must be living in a different reality.

Yes mine. At work I don't use pip. We have thousands of servers all using python and none using pip or modules obtained via pip before imaging.

Personally… I don't use pip. Why? apt is there.


It’s easier for you to rely on the volunteers that maintain python packages for Debian. That’s fine, but if you need something niche like cgi, you might have to package it yourself.

Because pypi is managed by paid people?

Also I'm part of the python team in debian so I can package what's missing or update out of date things if I need.


I appreciate your work! The Python team in Debian has saved me an enormous amount of effort over the years.

I doubt I did anything you use ;)



Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: