|
|
Log in / Subscribe / Register

Python packaging targets

By Jake Edge
February 22, 2023

Python packaging

As we have seen in earlier articles, the packaging landscape for Python is fragmented and complex, though users of the language have been clamoring for some kind of unification for a decade or more at this point. The developers behind pip and other packaging tools would like to find a way to satisfy this wish from Python-language users and developers, thus they have been discussing possible solutions with increasing urgency, it seems, of late. In order to do that, though, it is important to understand what specific items—and types of Python users—to target.

Integrator or user?

Steve Dower framed the overarching problems of Python packaging—and the discussion thereof—in terms of the types of users that are being targeted. There are distinct groups of users, but the Python packaging community has not defined its audience "so we keep trying to build solutions that Just Work™ for groups of people who aren't even trying to do the same thing, let alone using the same workflow or environment/platform". There are (at least) two roles, but they get conflated:

One concrete example that some of us have been throwing around for years: the difference between an "system integrator" and an "end user". That is, the person who chooses the set of package versions and assembles an environment, and the person who runs the Python command. They don't have to be the same person, and they're pretty clearly totally distinct jobs, but we always seem to act as if end users must act like system integrators (i.e. know how to install compilers, define constraints, resolve conflicts, execute shell commands) whether they want to or not. And then we rile against system integrators who are trying to offer their users a usable experience (e.g. Red Hat, Debian, Anaconda) for not forcing their users to also be system integrators.

[...] To end with a single, discussion-worthy question, and bearing in mind that we don't just set the technology but also the culture of Python packaging: should we be trying to make each Python user be their own system integrator, supporting the existing integrators, or become the sole integrator ourselves?

Paul Moore replied that the packaging community "should be supporting Python users". That means helping many of them not to have to be integrators, for others it means providing a path "to do a simplified integration job". In the dichotomy that Dowers outlined, integrators (and distributors) build the binary artifacts needed for the packages that are required, while users consume those artifacts typically via some form of package manager.

But it is also important that all of those users are able to get Python and its packages in a form that meets their needs, Moore said. He thinks that the community should be supporting the existing integrators (e.g. Linux distributions, Anaconda) and encouraging new ones for niches that are not well served, like "Windows users for whom conda isn't the right solution". But he does not think it makes sense for the Python community to become the sole integrator, unless the steering council wants to bring packaging inside the core-development tent.

If the packaging community wants to better support integrators/distributors, though, it needs cooperation from those integrators, Moore said. There also needs to be better documentation on the Python home page about how to get Python and how to choose an integrator if one is needed. Though the push from users seems to be for something that would include virtual-environment management and more (a la Rust's cargo), that may be a step too far for Python at this point; a unified package installer might be possible, however:

A common install command - either implemented in core Python with "hooks" for integrators to link to their own implementations, or a defined command like pyinstall which all integrators are required to implement with the same interface, so that the user experience is identical.

Python developers who want to do their own integration are important, Ralf Gommers said, but they are also over-represented in the discussion; most language users "want things to work well without too much trouble". He agreed with Moore that better supporting the existing integrators was the right goal. Moore pointed out that unifying the install command would allow the Python Package Index (PyPI) to switch from recommending "pip install" to something more generic; beyond that, though, "if we don't unify interfaces, how do we address this aspect of what users see as 'too many options'"? But Dower said that pip is the right choice for the unified command "because it is how you get packages from PyPI"; the missing piece is a way for pip to know that it should not be installing a package because it should come from the distributor/integrator:

I can imagine some kind of data file in the base Python install listing packages (or referencing a URL listing packages) that pip should warn before installing, and probably messages to display telling the user what they should prefer. Distributors could bundle this file in with their base Python package so that anyone using it gets redirected to the right source.

That would require more coordination between the developers of pip and those for other environments, such as conda and the Linux distributions, Moore said; the longtime message has been that pip is the wrong way to install packages system-wide on Linux, for example. He is not against the idea, but worries that it is not going to be user-friendly:

So users would go to PyPI, find instructions to do pip install X, try that and get told "nope, you should use apt-get install python-X instead"? That doesn't seem like it's going to reduce user confusion, I'm afraid... (It's OK for experienced users, but those are the sort of people for whom the current "be your own integrator" model is acceptable).

No matter what path is chosen, it is important to ensure that the community knows about it, Russell Keith-Magee said. In fact, the communication about the strategy "is just as important (if not more so) than the strategy itself", especially since "it's going to take months or years" to get to the desired end point. While the Python Packaging Authority (PyPA) is not exactly a standards body, it can help guide the community in the right direction:

However, even an informal statement declaring a vision and desired future state for Python packaging would be invaluable in terms of setting community expectations, generating convergence towards that desired future state, and guiding the contributions of those who might be inclined to help get there.

Building versus installing

Installing a package from PyPI can range from a simple, straightforward task, for pure Python packages, to extremely complex, requiring multiple compilers, build systems, and more. In the easiest cases, pip (or something like it) can simply copy a source distribution (sdist), which is a .tar.gz file, and install its files in the proper location so that import can find them. In more complicated cases, where there are dependencies on other PyPI packages, the pyproject.toml file can be consulted in order to pick up those dependencies (and, naturally, their dependencies) before installation. The sdist and pyproject.toml formats are described in PEP 517 ("A build-system independent format for source trees") and PEP 518 ("Specifying Minimum Build System Requirements for Python Projects").

If one or more of the dependencies requires a compiler in order to build a Python extension written in C, C++, Rust, or some other language, it is often up to the user to figure that out and install the right pieces, unless there is a wheel file available on PyPI for the installer's environment. The binary wheel file will contain a library that has already been built, so the build tools are not required. But the combinatorial explosion of environments makes it difficult for PyPI to have wheels available for all of them; this is especially true for packages like NumPy and SciPy, where speed is critical, so the libraries need to be optimized for the specific CPU instruction set and GPUs available.

One way to arrange for that is to split the job into two parts, as Hatch maintainer Ofek Lev described:

To be super specific here, for building a wheel with compiled bits you need 2 distinct things: a build backend and an extension module builder.

The build backend is the thing that users configure to ship the desired files in a zip archive which we call a wheel. The extension module builder is the thing in charge of compiling like cmake that will then communicate with the build backend to say what extra files should be included.

Lev thinks that his extensionlib toolkit provides the right model, though Gommers disagreed. The problem is that Lev is oversimplifying, Gommers said:

You seem to be under the impression that it's a matter of finding some compiler, pointing it at a few source files, and producing a .so/.dll. In reality, dealing with compiled code is (at least) an order of magnitude more complex than anything that any pure Python build backend does.

Henry Schreiner, who maintains several different packaging tools including the scikit-build build-system generator, noted that the packaging landscape has improved a great deal since the days of the "setuptools/distutils monopoly". In particular, setuptools and the now-deprecated distutils are painful for some kinds of projects to use (it "requires up to thousands of lines (14K in numpy [distutils], IIRC) to work"), which is not really maintainable. Instead of having a Python-based builder for extension modules, it makes sense to use external build tools, he said:

Certainly, in the compiled space, many/most users will want a build system like CMake or Meson - building a compiled extension from scratch is really hard, and not something I think we want to compete on. Reusing the years of work and thousands of pre-existing library integrations is valuable.

Gommers put together a lengthy blog post that described his vision for the path forward. That plan would severely restrict the kinds of packages that would come directly from PyPI ("only pure Python (or -any) packages from PyPI, and everything else from a system package manager"). There was some pushback on that, but Dower suggested softening the restriction somewhat, while looking for some consensus:

I think this thread is the place to agree that when a distributor has prebuilt binaries for their build of Python, those should be preferred over unmatched binaries. If we agree that the default workflows should somehow support that, we can do details in new threads.

So an Anaconda or Linux environment that has a binary version of some package available would use that binary in preference to any PyPI wheel that might—or might not—work in that environment. There are lots of wheels at PyPI that work fine outside of the specific environment they were built for; if they get installed on such a system they may not work, however "either in obvious ways (fails to import) or subtle ways (crashes at runtime, silent data corruption, etc.)", Dower said. The problem with the "get your binaries from a distributor" model, Moore said is that it generally means users need to get their Python from the same source:

And that means "switch to a different stack", which for many users is simply not acceptable (especially if they don't know this is going to happen in advance, which they typically don't).

If we were talking about distributors/integrators shipping binaries which worked with whatever Python installation the user had, there would be a lot less heat in this discussion. If I could install the Windows Store Python, and then find I needed to get (say) scipy from somewhere other than PyPI, and there was somewhere that shipped binaries that worked with the Windows Store Python, I wouldn't have the slightest problem (well, the UI of "pip fails, find the right command" needs to be worked out but that's a detail). But I've seen no sign of anyone offering that.

There's a reason no one is offering it, Dower said; it simply is not possible to do so:

The reason that binaries don't work with "whatever installation of Python the user has" is because you need to know about the installation in order to produce the binaries.

[...] Most of the time on many modern desktop and server machines, the ABI is usually close enough that you can squint and get away with it ("wheels which work for "most" users"). Once you get into the territory where that doesn't work, you do need to know all the details of the ABI in order to build a compatible binary for that interpreter. The easiest way to do this is to get the interpreter from the same builder you get the binary from, because they'll have ensured it.

In general, Dower's proposed agreement was well-received, but Moore thought that is was only handling the easy part: "The difficult question is when a distributor doesn't have prebuilt binaries, what should happen?" The right answer, according to Dower, is to request that the distributor provide the package and, failing that, to build it from source "using the distributor's environment as the target"; that way the resulting binary module is compatible with the distribution.

The discussion roared on, but along the way Moore stepped back to look at the overall goal of the discussion. If someone were to wave a magic wand that resulted in a consensus on the single tool to use: "What would we then actually do to make that consensus effective?" He does not have a good answer to that question, but it feels like the community "expects the PyPA to have some sort of influence (or authority) over this, and our biggest issue is basically that we don't..."

Clearly communicating the recommendation would be what many users are looking for, Oscar Benjamin said. "If PyPA said 'we now recommend tool X' and there was clear documentation for using it and migrating to it then I would be happy to go along with that. I think that's where most users are at." Moore was unsure how the PyPA could actually accomplish that: "I genuinely don't know how the average user distinguishes between a formal recommendation from the PyPA and a bunch of random documentation they found on the internet. Is packaging.python.org genuinely that influential?" But Dower thought there was a straightforward answer to that: "I suspect for most users, 'preinstalled with the python.org installer and on PATH by default' is what it would take." Moore agreed; "Now all we have to do is agree what tool to distribute ;)"

There are, of course, several possibilities for which tool that might be, but obviously pip is in a rather privileged position, since it is already shipped with Python. Whether pip can be adapted to be the grand, unified tool was discussed further as the strategy thread began to wind down—after nearly 300, often lengthy, posts. The rest of the discussion on which tool—and how to make that decision—will come in our next installment.


Index entries for this article
PythonPackaging


to post comments

Python packaging targets

Posted Feb 23, 2023 6:16 UTC (Thu) by marcH (subscriber, #57642) [Link]

> Steve Dower framed the overarching problems of Python packaging—and the discussion thereof—in terms of the types of users that are being targeted.

Speaking of framing the discussion, a good reference:
https://medium.com/@sdboyer/so-you-want-to-write-a-packag...

Python packaging targets

Posted Feb 23, 2023 14:30 UTC (Thu) by hrw (subscriber, #44826) [Link] (16 responses)

Binary compatibility is kind of sorted out with manylinux environments. But they are based on old releases of distributions so it can be hard to collect all build dependencies.

Forcing to install from distribution is wrong. What if current distro release has 1-2 years old package only and we need features from newer one? Change distro or distro release?

Python packaging targets

Posted Feb 24, 2023 6:08 UTC (Fri) by cyperpunks (subscriber, #39406) [Link] (15 responses)

> What if current distro release has 1-2 years old package only and we need features from newer one?

It's very simple, but it seems to a be a secret for most users:

You create a bug against the package in distro and ask for upgrade.

If the upstream maintainer has done development corrretlt and not broken backward compatibility and all packages that depend on the package by explicit version check has used equal and greater than (>=) and not equal, it takes distro maintainer 1-2 hours work to import new version, build it and send update to repos. After 3-7 days in testing (you can enable testing repo to the package the next day) new version will be availalble for all users in the distro.

If upstream maintainer has broken backward compatibility the distro maintainer must check all packages that depend on the problematic package and ping maintainers of all borken packages due to the borken backward compatibility. The distro maintainer of the now borken package must now check if a fix exist or resolve it by a local fix or stop the upgrade of your package.

If upgrade A of forces upgrade of package B, the whole process must be repeated for package B so on to all deps have been resolved.

As seen the amount of work needed is direct product of how upstream maintainers of packages does development. If they don't break backward compatibility and use sane version requirement expressions an package upgrade is available for all users in a few days.


Python packaging targets

Posted Feb 24, 2023 7:45 UTC (Fri) by hrw (subscriber, #44826) [Link] (5 responses)

Not every distribution is rolling release one.

I have systems with Debian stable. Some stuff can be updated thanks to backports repo but there are Debian developers who do not do backports.

Python packaging targets

Posted Feb 24, 2023 11:32 UTC (Fri) by cyperpunks (subscriber, #39406) [Link] (3 responses)

This is not rolling, it's simple update of a package. All sane distros should allow that?

Python packaging targets

Posted Feb 24, 2023 12:19 UTC (Fri) by TomH (subscriber, #56149) [Link] (2 responses)

Not really - stable distros usually try to limit updates within a release to bug fixes. See for example the Fedora policy:

https://docs.fedoraproject.org/en-US/fesco/Updates_Policy...

Python packaging targets

Posted Feb 24, 2023 20:33 UTC (Fri) by cyperpunks (subscriber, #39406) [Link] (1 responses)

Well, since Fedora 37 GA there have been about 500 updates per month:

https://bodhi.fedoraproject.org/releases/F37

Python packaging targets

Posted Feb 24, 2023 22:09 UTC (Fri) by rahulsundaram (subscriber, #21946) [Link]

> Well, since Fedora 37 GA there have been about 500 updates per month:

Fedora has ~70000 packages. So 500 is still a pretty small number of updates in comparison. Also keep in mind that Fedora's updates tend to far more liberal (semi rolling) in practice compared to say RHEL, Debian or Ubuntu. It is quite common for folks to find that their distribution doesn't ship with the version of something they want if they are looking for closer to the latest.

Python packaging targets

Posted Mar 2, 2023 7:09 UTC (Thu) by oldtomas (guest, #72579) [Link]

If it's Debian we are talking about, and if the upgrade itself is source-compatible (which was assumed upthread) then creating a backport isn't much more difficult than pip-installing something: just download the source .deb, unpack it, install the build depencencies (which you must, perhaps, tweak to reflect what you have on your stable), perhaps tweak some dependencies, then dpkg-buildpackage.

Compared with some boxes I meet regularly at work, which are "lots of little .venv directories, all alike", this might be a nicer option, after all.

Python packaging targets

Posted Feb 24, 2023 23:42 UTC (Fri) by rra (subscriber, #99804) [Link] (8 responses)

I am afraid this is excessively optimistic, even apart from the general principle that the point of stable distributions is to not do this.

Common problems that prevent the distribution from just updating to a new version:

1. The new version broke backward compatibility in some way (possibly intentionally, possibly by accident), and now other packages that depend on it don't work and also need to be updated (or may not have updates available yet).
2. The new version drops support for older versions of Python that are supported in that release of the distribution.
3. The new version has new dependencies on Python packages that aren't already packaged.
4. The new version has new dependencies on C libraries or Rust crates or what have you that aren't already packaged.

There are some extremely well-behaved Python libraries that never break backward compatibility and support a wide range of versions, but this is quite a lot of work and a lot of maintainers don't do this, either due to lack of time or because this isn't how they want to spend their resources and effort.

One of the reasons why this discussion is so difficult is that system integration is a substantial amount of ongoing work. Things break. A lot. And quite a lot of this work is volunteer.

Python packaging targets

Posted Feb 25, 2023 7:45 UTC (Sat) by cyperpunks (subscriber, #39406) [Link] (1 responses)

All this is true.

The quality of software available in pypi varies a lot and some packages break compability in a random minor upgrade.

To "resolve" this owners of other projects using the project with borken compability pin version requirement to a specific version.
This is also careless, as now is any project that needs a new of version of problematic package blocked from being installed.

The reason is that Python has global name space, there can be only version of problematic package installed and this package must
be present at runtime. Python is special here. Rust or Golang can create a suitable build environment, create binaries, install and software will run forever.

Python has the worst mix of all: an easy to learn language which causes lots of low quality package to be published to repos, careless owners which break compability, even more careless owners which pin version requirements combined with globale namespace and
no different between build and runtime environment.

The future of this is not promising.


Python packaging targets

Posted Feb 25, 2023 21:59 UTC (Sat) by NYKevin (subscriber, #129325) [Link]

> The reason is that Python has global name space, there can be only version of problematic package installed and this package must be present at runtime. Python is special here. Rust or Golang can create a suitable build environment, create binaries, install and software will run forever.

It very much is *possible* to make hermetic builds of Python. It's just that there's so much you need to package, that you are effectively bundling an entire Python installation (like Flatpak etc.). Distros don't like this degree of vendoring, but they also have problems with Go and Rust.

Python packaging targets

Posted Mar 2, 2023 8:27 UTC (Thu) by callegar (guest, #16148) [Link] (5 responses)

This would be easier if you could

apt install some-python-pkg-1.0

/and/ also

apt install some-python-pkg-2.0

without having the latter replace the former. It would allow the distro to provide the new package, while temporarily maintaining stuff that might get broken with the old package.

In fact, given the python approach of not allowing this kind of thing, I now tend to think that a few things would be simpler if there was a policy so that at least the "major" version of the package was formally required to become a part of the package name. Even without a formal requirements, for some packages this seems to be already done.

Python packaging targets

Posted Mar 2, 2023 17:58 UTC (Thu) by mathstuf (subscriber, #69389) [Link] (4 responses)

How do you propose these two package co-exist on the disk? If both are installed, what does `import some_python_pkg` do?

Python packaging targets

Posted Mar 2, 2023 21:19 UTC (Thu) by nix (subscriber, #2304) [Link] (2 responses)

Sorts and picks the highest version number (using standard version sorting), unless a suitable piece of metadata in the installed package directory (or import line, since obviously we'd want to augment that and allow version ranges!) specifies otherwise.

This is not rocket science. It's just a tricky compatibility and syntax thing.

Python packaging targets

Posted Mar 3, 2023 0:43 UTC (Fri) by mathstuf (subscriber, #69389) [Link] (1 responses)

> This is not rocket science. It's just a tricky compatibility and syntax thing.

Isn't this kind of the use case that this whole article series has been about though? It might not be rocket science, but it certainly doesn't seem easy. We (as a species) actually seem to be better at rocket science if you were to ask me…

Corner cases that come to mind:

- Two libraries provide metadata to describe their dependencies and they disagree about what version to use.
-- What is preferred?
-- Does every library/application need to specify their full transitive requirements?
- How do I prod random script developers to provide this information? Can it be specified in-source or is it sidecar metadata?
- If they are allowed to co-exist, what does `sys.modules` look like now?

Python packaging targets

Posted Mar 3, 2023 13:30 UTC (Fri) by nix (subscriber, #2304) [Link]

> - Two libraries provide metadata to describe their dependencies and they disagree about what version to use.

I don't see how (in the absence of hermetic namespacing) this can be anything but a runtime error. Of course, again, other languages can do this easily...

> - How do I prod random script developers to provide this information? Can it be specified in-source or is it sidecar metadata?

I was assuming both: a file in the package directory versioning lots of things at once, or extra syntax for import. Sidecar seems totally wrong: this is something *the package* is expecting, not something the admin is supposed to be nailing down (how could the admin possibly know the right answer?)

Obviously if a given import doesn't have a version nailed in, the system works exactly as it does now: anything else would be a compatibility disaster. (Needless to say I have written none of this code so I'm totally bikeshedding and waving away all the no-doubt-horrible problems!)

Python packaging targets

Posted Mar 2, 2023 21:19 UTC (Thu) by atnot (guest, #124910) [Link]

Like in many other language ecosystems (and even sort of python with virtualenv), there would be some shim that tells the interpreter/compiler what packages the program should have available in what version. This would be read from some sort of file provided along with the program or source code.

Python packaging targets

Posted Feb 24, 2023 12:23 UTC (Fri) by nbecker (subscriber, #35200) [Link]

I use Fedora. The proposal is that if fedora already packages a python module, I should get it from there and not from pypi. The problem is that fedora modules are updated much slower than pypi, and I often want or need the newer version, so install from pypi.

Python packaging targets

Posted Feb 24, 2023 19:20 UTC (Fri) by jsanders (subscriber, #69784) [Link] (1 responses)

The Python packaging ecosystem just seems to be getting worse and worse, as a developer. There's more and more complexity, too much magic and perversely less freedom. For example, my Python-based GUI application is built with distutils, which is being deprecated. It seemed like setuptools was the obvious choice to replace distutils, but it's much more limited. For example, the method to ship files outside of the python module directory is now deprecated in setuptools. Therefore you can't ship man pages, examples etc, if needed, which is a big pain for an application for linux. There's the disaster area of pip which likes to download random things and change your install without telling you, while also making it hard to build from source. You also get the joy of endless messages about support for setup.py going away when you install stuff now. More and more half-baked stuff is added to the pile each year. It makes one even yearn for using autotools.

Python packaging targets

Posted Feb 24, 2023 20:36 UTC (Fri) by cyperpunks (subscriber, #39406) [Link]

Yeah, things are now so bad Python can not be recommended for software projects that ship to external users.

Project written in Python is more or less impossible to deploy and update in sane manner.

Python packaging targets

Posted Mar 27, 2023 16:08 UTC (Mon) by sammythesnake (guest, #17693) [Link] (2 responses)

I've been doing a lot of in-the-background thinking about the *many* difficult packaging situations that get lots of discussion here and elsewhere. I'm mostly coming from a desire tokeep the advantages my distribution-provided package management has while still allowing for random programs to do stupid stuff without breaking the world.

It seems to me that there are two particularly key things that distros and various non-distro package/dependency management systems could agree to cooperate on that would make a huge difference and would likely consolidate a lot of the stuff we're endlessly fighting against into a relatively simpler set of problems with much more shared code/behaviour (though still involving a chunk of new work!)

1. Distros should be much happier having multiple versions of the same package available, with suitable cleverness to provide the "correct' version to any software that runs

2. Tools like pip/cargo/npm/uncle Tom Cobley and all should be able to make use of the OS provided package manager to satisfy dependencies where suitable versions are available.

Imagine a conversation something like this:

UTC: $OS, I'm installing Package_FOO v1.1, it depends on Package_BAR>=1.1<2.2, Package_BAZ>=5.5<7.7, and Package_QUX>=6.3

$OS: I can provide Package_FOO 1.5, 1.6, or 1.7, and Package_BAZ 5.8, but no Package_QUX

UTC: Here's Package_QUX 6.9, and Package_FOO v1.1

$OS: Gotcha, Fam!

Then whenever Package_FOO is used, it gets suitable versions of its dependencies, possibly using some magic with containers and bind/union mounts to de-dup a bunch of stuff.

If we've got this in place, it would also potentially make it easier to support a variety of non-privileged package installation stories, which could be exciting...

There are a lot of hairy details to sort out, of course, but I can't help thinking this is a potential way towards happiness!

Hairy details that occur to me:

1. Version specifications will probably be a lot more complex than in my example, including multiple allowable version ranges, details of how the packages are built (which CPUs are supported, which features are enabled etc.) and more.

2. The dependency graph for some packages might be arbitrarily complex, so we'd probably end up with UTC providing the whole graph to $OS to sort out multiple possible combinations

3. The upgrade story needs some care(!) We'd want to allow $OS to upgrade Package_BAR to 1.9 and remove 1.7 when no packages depend on it, with the user able to control which packages get their dependencies upgraded when. This is basically the same as a normal distro upgrade process except that different packages might have different upgrade schedules, as well as different version requirements.

4. We'd want users (and sysadmins) to have suitable policy control over how UTC-provided package are shared (single package only, per user, per non-distro-provider, system wide...)

5. The interface at which "Packages" meet is *complex*. Version requirements and matching will likely be different depending on whether we're talking about dynamic linking to libraries, calling external binaries, connecting to other processes over pipes/networks...

6. Obligatory https://xkcd.com/927/

7. All the still remaining reasons why Package Management Is Hard that this idea doesn't address.

8. The whole concept is a half-baked cockamamie wild goose chase dreamt up by a chump who would need much smarter people to shoot it down / fix it / implement it :-P

Python packaging targets

Posted Mar 27, 2023 16:46 UTC (Mon) by pizza (subscriber, #46) [Link]

> 1. Distros should be much happier having multiple versions of the same package available, with suitable cleverness to provide the "correct' version to any software that runs

Distros are already fundamentally able to do this in the general sense, but the individual languages/runtimes/whatever need to support [semantically] versioned package namespaces, and enforce that through culture... and tooling that does the right thing by default.

Python packaging targets

Posted Mar 27, 2023 20:49 UTC (Mon) by Wol (subscriber, #4433) [Link]

You're describing pretty much what I tried to get into the LSB. We're talking early 90s - that's THIRTY yearts ago, and there's been f-all progress ...

We need a PACKAGE to be able to pass a list of requirements to the OS. There's no damn use the OS telling a package what it's got, it needs the package to tell it what it requires. I wanted to enable proprietary packages to pass their list of dependencies to the OS, but the same principle holds for FLOSS software as well - it needs to be able to tell the OS what it needs.

Given my complete lack of success, I doubt you'll do any better :-( The LSB was all about the package being able to ask "have you got lsb package X?", bugger all use to your normal user ...

Cheers,
Wol


Copyright © 2023, Eklektix, Inc.
This article may be redistributed under the terms of the Creative Commons CC BY-SA 4.0 license
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds