On Wed, Oct 20, 2010 at 6:35 PM, Floris Bruynooghe <span dir="ltr"><<a href="mailto:flub@devork.be">flub@devork.be</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br><div class="im">
On 20 October 2010 15:27, Tarek Ziadé <<a href="mailto:ziade.tarek@gmail.com">ziade.tarek@gmail.com</a>> wrote:<br>
> On Wed, Oct 20, 2010 at 4:00 PM, Paul Moore <<a href="mailto:p.f.moore@gmail.com">p.f.moore@gmail.com</a>> wrote:<br>
</div><br><div class="im">>> But I'm probably not seeing the real issues here.<br>
>><br>
>> All I would say is, don't let the needs of more unusual configurations<br>
>> over-complicate basic usage.<br>
><br>
> The trouble is: adding in PYTHONPATH the root of the source of your<br>
> project can be different from what it would be once installed in<br>
> Python. Now the question is: if 90% of the projects out there would<br>
> work by adding the root, then this is might be overkill. I am afraid<br>
> it's way less though...<br>
<br>
</div>I've read your and Ian's responses and still don't understand what<br>
setup.py develop brings to the party which can't be done with simple<br>
PYTHONPATH. Excuse me if I also completely misunderstand what develop<br>
does but it sounds like it's going to add an in-development version of<br>
a project on a users's sys.path (at the front?) until it's undone<br>
again somehow (is there a "setup.py undevelop"?).</blockquote><div><br>pip uninstall would unlink it (pip install -e calls setup.py develop as well). setup.py develop is persistent unlike PYTHONPATH.<br> </div>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"> This just seems<br>
dangerous to me since it will affect all python programs run by that<br>
user.<br></blockquote><div><br>Hence virtualenv, which solves your other concerns.<br> </div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
If I understand correctly this whole "develop" dance is for when you<br>
have two inter-depended packages in development at the same time. If<br>
manually setting PYTHONPATH correctly in this situation is too<br>
complicated then my feeling is there's nothing wrong with some sort of<br>
helper which manipulates PYTHONPATH for you, something like spaw a new<br>
shell and set the environment in that correctly. But placing things<br>
in files makes this permanent for the user and just seems the wrong<br>
way to go to me.<br>
<br>
Again, apologies if I understand the problem wrongly. But I too am<br>
worried about too many complexities and "magic". One of my main<br>
issues with setuptools is that it tries to handle my python<br>
environment (sys.path) outside of normally expected python mechanisms<br>
by modifying various custom files. I would hate to see distutils2<br>
repeat this.<br></blockquote><div><br>Note if you use pip, it uses setuptools in a way where only setup.py develop uses .pth files, and otherwise the path is similar to how it is with distutils alone (except with that extra metadata, as Doug mentions).<br>
<br></div></div>-- <br>Ian Bicking | <a href="http://blog.ianbicking.org">http://blog.ianbicking.org</a><br>