msg137495 - (view) |
Author: Tshepang Lekhonkhobe (tshepang) * |
Date: 2011-06-02 20:09 |
If I happen to not have the directory, $PREFIX/python3.3/site-packages, I get an erroneous message telling me that I don't write permissions.
|
msg137531 - (view) |
Author: Éric Araujo (eric.araujo) * |
Date: 2011-06-03 15:44 |
This looks like an invalid bug to me; Python itself creates the site-packages directory, with a README file if I remember correctly. If the sysadmin removes the directory, it’s their problem, not a Python bug. Do you agree?
|
msg137536 - (view) |
Author: Tarek Ziadé (tarek) * |
Date: 2011-06-03 15:50 |
This is probably because Tshepang works in a dev environment.
I think we should have a nice message like "The installation path xxx seems not to exist, aborting installation"
|
msg137537 - (view) |
Author: Éric Araujo (eric.araujo) * |
Date: 2011-06-03 15:52 |
Hm, in my dev environment (checkout of 3.3), site-packages exists.
|
msg137538 - (view) |
Author: Tarek Ziadé (tarek) * |
Date: 2011-06-03 15:58 |
Strange, you should get a /usr/[local]/lib/python3.3/site-packages when you just run "./configure; make"
It looks like you have a dev environment that has installed some stuff
|
msg137539 - (view) |
Author: Tarek Ziadé (tarek) * |
Date: 2011-06-03 15:58 |
s/should get/should not get/
|
msg137547 - (view) |
Author: Éric Araujo (eric.araujo) * |
Date: 2011-06-03 16:18 |
Ah, I understand; I have a $srcdir/Lib/site-packages directory, but packaging wants to install into $prefix/site-packages, which does not exist. +1 to adding a nice message. Tshepang, would you like to update your patch?
|
msg137570 - (view) |
Author: Tshepang Lekhonkhobe (tshepang) * |
Date: 2011-06-03 18:56 |
On Fri, 2011-06-03 at 16:18 +0000, Éric Araujo wrote:
> Éric Araujo <merwok@netwok.org> added the comment:
>
> Ah, I understand; I have a $srcdir/Lib/site-packages directory, but packaging wants to install into $prefix/site-packages, which does not exist. +1 to adding a nice message. Tshepang, would you like to update your patch?
Why not just create the directory, instead of print the warning? Is
there any harm?
|
msg137639 - (view) |
Author: Éric Araujo (eric.araujo) * |
Date: 2011-06-04 14:38 |
We do not want to create a directory under $prefix before installation. This would be a sort of dirty half-installation. When you have an uninstalled, unconfigured Python, you cannot install modules without giving a prefix option: this sounds good to me.
|
msg137670 - (view) |
Author: Tshepang Lekhonkhobe (tshepang) * |
Date: 2011-06-05 00:07 |
But this part of the code runs only when you want to install a 3rd party module isn't it? What you are proposing simply adds a delay, for the use will have to then add that directory manually. Or is there something I'm missing here?
|
msg137671 - (view) |
Author: Tshepang Lekhonkhobe (tshepang) * |
Date: 2011-06-05 00:09 |
s/use/user
|
msg137708 - (view) |
Author: R. David Murray (r.david.murray) * |
Date: 2011-06-05 19:16 |
I'm not sure I understand your confusion, but perhaps what you are missing is that we don't support installing 3rd party packages inside a source tree, only into an installed Python, and installing Python creates the site-packages directory in $prefix.
|
msg137709 - (view) |
Author: Tshepang Lekhonkhobe (tshepang) * |
Date: 2011-06-05 19:44 |
Are there cases where my patch would result in site-packages directory installed in an unwanted place?
|
msg137710 - (view) |
Author: R. David Murray (r.david.murray) * |
Date: 2011-06-05 19:54 |
Yes. If the directory gets created without Python being installed, then you don't have a working python installation. Assuming we are talking about site-packages. I have no idea what purelib is or anything about the packaging internals.
|
msg137715 - (view) |
Author: Tshepang Lekhonkhobe (tshepang) * |
Date: 2011-06-05 20:39 |
I've changed the patch to represent what I've since learned. It now just displays a message, instead of silently creating the missing path.
|
msg137746 - (view) |
Author: Éric Araujo (eric.araujo) * |
Date: 2011-06-06 15:57 |
Thanks. What about using sysconfig.is_python_build in your patch?
|
msg137768 - (view) |
Author: Tshepang Lekhonkhobe (tshepang) * |
Date: 2011-06-06 19:10 |
Find attached.
|
msg137951 - (view) |
Author: Éric Araujo (eric.araujo) * |
Date: 2011-06-09 11:46 |
Great! I will edit a bit the message and commit this.
|
msg138107 - (view) |
Author: Roundup Robot (python-dev) |
Date: 2011-06-10 16:35 |
New changeset ff58eec3336b by Éric Araujo in branch 'default':
Don’t try to install something when running from uninstalled source (#12246).
http://hg.python.org/cpython/rev/ff58eec3336b
|
msg138108 - (view) |
Author: Éric Araujo (eric.araujo) * |
Date: 2011-06-10 16:46 |
Fixed. Welcome to Misc/ACKS !
|
msg138131 - (view) |
Author: Tshepang Lekhonkhobe (tshepang) * |
Date: 2011-06-10 20:05 |
On Fri, 2011-06-10 at 16:46 +0000, Éric Araujo wrote:
> Éric Araujo <merwok@netwok.org> added the comment:
>
> Fixed. Welcome to Misc/ACKS !
loveliness :)
|
msg147500 - (view) |
Author: Éric Araujo (eric.araujo) * |
Date: 2011-11-12 15:25 |
Paul Moore reported that a Python built in its checkout on Windows has no problem installing, so I’d like to revisit this. The patch was also incomplete: The install module was changed, but people could still call “pysetup run install_dist”, and that command was not touched.
To support this on Unix too, we have to either fix sysconfig (#6087) or override some sysconfig paths in packaging.
I will shoot an email at python-dev. There is no pattern for Lib/site-packages in .hgignore, which makes me think that this issue just never showed up before; I think I need approval before I go ahead.
|
|
Date |
User |
Action |
Args |
2022-04-11 14:57:18 | admin | set | github: 56455 |
2014-03-13 03:34:47 | eric.araujo | set | status: open -> closed resolution: out of date stage: needs patch -> resolved |
2011-11-12 15:25:02 | eric.araujo | set | status: closed -> open
title: Warn when trying to install third-party module from an uninstalled checkout -> Support installation when running from an uninstalled Python nosy:
+ paul.moore
messages:
+ msg147500 resolution: fixed -> (no value) stage: resolved -> needs patch |
2011-06-10 20:05:12 | tshepang | set | messages:
+ msg138131 |
2011-06-10 16:46:09 | eric.araujo | set | status: open -> closed type: behavior -> enhancement messages:
+ msg138108
resolution: fixed stage: commit review -> resolved |
2011-06-10 16:35:06 | python-dev | set | nosy:
+ python-dev messages:
+ msg138107
|
2011-06-09 11:46:37 | eric.araujo | set | type: behavior messages:
+ msg137951 stage: commit review |
2011-06-07 22:27:48 | tshepang | set | files:
+ display_warning_with_test.patch |
2011-06-06 19:10:24 | tshepang | set | files:
+ display-warning_try2.diff
messages:
+ msg137768 |
2011-06-06 15:57:05 | eric.araujo | set | assignee: tarek -> eric.araujo messages:
+ msg137746 title: create installation path if it's non-existent -> Warn when trying to install third-party module from an uninstalled checkout |
2011-06-05 20:39:31 | tshepang | set | files:
+ display-warning.diff
messages:
+ msg137715 |
2011-06-05 19:54:11 | r.david.murray | set | messages:
+ msg137710 |
2011-06-05 19:44:54 | tshepang | set | messages:
+ msg137709 |
2011-06-05 19:16:27 | r.david.murray | set | nosy:
+ r.david.murray messages:
+ msg137708
|
2011-06-05 00:09:03 | tshepang | set | messages:
+ msg137671 |
2011-06-05 00:07:19 | tshepang | set | messages:
+ msg137670 |
2011-06-04 14:38:53 | eric.araujo | set | messages:
+ msg137639 |
2011-06-03 18:56:38 | tshepang | set | messages:
+ msg137570 |
2011-06-03 16:18:57 | eric.araujo | set | messages:
+ msg137547 |
2011-06-03 15:58:57 | tarek | set | messages:
+ msg137539 |
2011-06-03 15:58:46 | tarek | set | messages:
+ msg137538 |
2011-06-03 15:52:47 | eric.araujo | set | messages:
+ msg137537 |
2011-06-03 15:50:03 | tarek | set | messages:
+ msg137536 |
2011-06-03 15:44:43 | eric.araujo | set | messages:
+ msg137531 |
2011-06-02 20:09:01 | tshepang | create | |