Hi! Slightly off topic, but related to Python and dependencies. Is there a way to make a port depend on the latest stable version of Python? I’ve had many cases where one piece of software ends up requiring 2 or 3 different Python versions because the owners of its dependencies haven’t bothered to update the hard coded Python versions in their portfiles. I understand that version limiting may be required due to incompatibilities, but most of the time this is not the case.
Also when developing software, to upgrade Python I need to reinstall the whole dependent library tree and make sure that everything I need has already been updated for the new Python version. All the best, Johan > On 1. Jul 2026, at 16:53, Joshua Root <[email protected]> wrote: > > On 1/7/2026 16:35, Vincent Habchi wrote: >> If I understand the documentation correctly, using python.versions in non >> py-* ports results in mostly nothing. Only python.default_version seems to >> be honoured. >> My question is: wouldn’t it be sensible to automatically create variants >> based on python.versions (e.g python.versions 314 315 → +python314 >> +python315 variants automatically generated), with a default version set to >> whatever python.default_version binds to, so that the user would have a way >> to control which python version every Python-dependent application member of >> the Python portgroup uses, not just the py-* modules? > Ideally ports that use python and aren't modules that will be imported by > other python code should just use the current stable version. I'd like to > avoid further scope creep in the python portgroup, and I've mentioned more > than once in the past that it would be fine to add a new portgroup to create > these variants for the ports that want it, but apparently so far nobody has > found it worth the effort. That may be because it only ends up being around > 10 lines of code. > > - Josh
