On Tue, Feb 19, 2019 at 3:29 PM Philip Bergen via Python-ideas < python-ideas@python.org> wrote:
> First attempt at this, so please be gentle. :) > I am very interested in the overall goal of not needing virtualenvs, but > I'm curious about the motivations behind pep-582. > In a word, simplicity. Teaching newcomers about virtual environments is a stumbling block, but so if when they accidentally pollute their global installation when they get started.PEP 582 is an attempt to handle the simple case nicely. > Could someone help me understand if this has previously been discussed and > in that case why it was decided against? > 1: Why only look in CWD and not traverse root-wise? > Surprise, potential security implications, other languages that have a similar solution don't do that. > 2: It feels to me like there is a larger story here about sprucing up > PYTHONPATH. > It's been a common theme that when people read PEP 582 they think there's a larger story, so you're not alone. :) > > About 2) I would prefer if we had a mechanism to automatically look for > .pythonpath.pth (or something with a better name, but to that effect). Then > we were not limited to a specific directory or location. This would > streamline cross project repos, for instance: you could have docker images > that came preloaded with common libraries and just add a layer with your > specifics in a different directory earlier in the paths specified by > .pythonpath.pth > > Using pip to install into your directories of choice is already supported, > although perhaps we should have some way of telling it to use the first > entry in .pythonpath.pth. > PEP 582 isn't about sharing installs, so I think your idea is orthogonal to its goals. -Brett > > I would be very grateful for some interaction on this. If there is general > interest I could submit some working code. > > Thanks, > // Phil > > -- > *Philip Bergen* > P: +1(415)200-7340 > *"Without data you are just another person with an opinion" -- W. Edwards > Deming* > _______________________________________________ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ >
_______________________________________________ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/