View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0004385 | Taler | obsolete component | public | 2016-04-07 23:03 | 2016-04-09 01:50 |
Reporter | Christian Grothoff | Assigned To | Florian Dold | ||
Priority | immediate | Severity | block | Reproducibility | have not tried |
Status | closed | Resolution | fixed | ||
Platform | i7 | OS | Debian GNU/Linux | OS Version | squeeze |
Product Version | 0.0 | ||||
Target Version | 0.0 | Fixed in Version | 0.0 | ||
Summary | 0004385: can't run 'make install' for bank because it ignores prefix | ||||
Description | After running 'configure --prefix=/home/grothoff', I get: $ make install running install error: can't create or remove files in install directory The following error occurred while trying to add or remove files in the installation directory: [Errno 13] Permission denied: '/usr/local/lib/python2.7/dist-packages/test-easy-install-32086.write-test' The installation directory you specified (via --install-dir, --prefix, or the distutils default setting) was: /usr/local/lib/python2.7/dist-packages/ Perhaps your account does not have write access to this directory? If the installation directory is a system-owned directory, you may need to sign in as the administrator or "root" account. If you do not have administrative access to this machine, you may wish to choose a different installation directory, preferably one that is listed in your PYTHONPATH environment variable. For information on other options, you may wish to consult the documentation at: https://pythonhosted.org/setuptools/easy_install.html Please make the appropriate changes for your system and try again. Makefile:25: recipe for target 'install' failed make: *** [install] Error 1 This should not happen as with --prefix, it should install to /home/grothoff, not /usr. | ||||
Tags | No tags attached. | ||||
|
With the new setup, --prefix only dictates where to put the final shell scripts. Instead, all python files are installed by setuptools, which in your case tries to install them in the "system" directory (since, as it seems, you have no virtualenv active). So it requires superuser rights. Yes, the virtualenv creation is not managed by configure/make anymore, but we preferred to cut off the "acrobatics" needed to activate virtualenv on behalf of the user.. |
|
That's a bit odd. If we just use setuptools, then we should also use that to install the shell scripts. And setup.py does, per default, support --prefix. |
|
Installation still fails with --prefix. First, pip3 doesn't recognize --prefix, using http://stackoverflow.com/questions/25333640/pip-python-differences-between-install-option-prefix-and-root-and I fixed it by adding --install-option around it in c171168..4a9a81c. Now it recognizes the option, but 'make install' still fails: Exception: Traceback (most recent call last): File "/usr/lib/python3/dist-packages/pip/basecommand.py", line 122, in main status = self.run(options, args) File "/usr/lib/python3/dist-packages/pip/commands/install.py", line 295, in run requirement_set.install(install_options, global_options, root=options.root_path) File "/usr/lib/python3/dist-packages/pip/req.py", line 1436, in install requirement.install(install_options, global_options, *args, **kwargs) File "/usr/lib/python3/dist-packages/pip/req.py", line 672, in install self.move_wheel_files(self.source_dir, root=root) File "/usr/lib/python3/dist-packages/pip/req.py", line 902, in move_wheel_files pycompile=self.pycompile, File "/usr/lib/python3/dist-packages/pip/wheel.py", line 214, in move_wheel_files clobber(source, lib_dir, True) File "/usr/lib/python3/dist-packages/pip/wheel.py", line 204, in clobber os.makedirs(destdir) File "/usr/lib/python3.5/os.py", line 241, in makedirs mkdir(name, mode) PermissionError: [Errno 13] Permission denied: '/usr/local/lib/python3.5/dist-packages/validictory-1.0.1.dist-info' Storing debug log for failure in /home/grothoff/.pip/pip.log Makefile:30: recipe for target 'install' failed Did you ever test this? |
|
Tried replacing --prefix with --target, result is that it basically trashed my $HOME with a crapload of Python garbage. Also, 'make install' re-downloads a metric shitload of dependencies each time. Not acceptable. Please make sure: 1) configure checks for Python.h properly 2) configure --prefix works on Debian systems 3) no re-downloading of resources again and again each time there is some small failure in the end! |
|
And 4) if the thing installs stuff, it should be: $PREFIX/bin: the main two binaries $PREFIX/{lib,share}/{taler-bank/}-rest-of-the crap. |
|
See my recent mail about pip. Recent versions of pip support --prefix just fine, just not the ancient version that ships with debian. Of course we should check that we have a recent-enough version of pip, but that's not trivial with autoconf. |
|
Binaries are already installed in $PREFIX/bin, the rest is installed in $PREFIX/lib. And no, "make install" does not re-download dependencies. The ancient debian version might, but recent ones don't. |
|
See https://pip.pypa.io/en/stable/reference/pip_install/#cmdoption--prefix |
|
I now tried with Debian unstable, pip 8.1.1. Result: $ pip3 install --prefix=/home/grothoff/ . ERROR: Can not combine '--user' and '--prefix' as they imply different installation locations |
|
Also, if you require a very recent pip3, configure should test that the installed version is recent enough. |
|
It should be $ cd taler/bank # where our setup.py is $ pip3 install . --prefix=/home/grothoff/ (note the dot, i.e. install the package defined in the current directory). And yes, we should check for a recent enough version. Again, please see my email about difficulties with this. |
|
Makes no difference: grothoff@spec:~/research/taler-bank$ pip3 install . --prefix=/home/grothoff/ ERROR: Can not combine '--user' and '--prefix' as they imply different installation locations |
|
This is very weird (you're obviously not specifying the user configuration). Could this be an issue with a broken configuration somewhere, similar to [1]? I'm trying to reproduce this, but both in my machine (Arch) and on tripwire inside a virtualenv it just works ... [1] http://stackoverflow.com/q/4495120 |
|
A workaround for now would be to install it with just --user. Python generally does not seem to play well with an arbitrary prefix it seems. |
|
Even when installing python3-pip on tripwire and upgrading it (pip3 install -U pip) I can't reproduce it, so it works inside and outside of virtualenvs. No idea what's going wrong here ... |
|
Could you please try running $ pip3 install . --prefix=/home/grothoff/ --isolated from the root of the bank repository? This should prevent any bad configuration files from e.g. adding "--user" as the default that messes with --prefix. |
|
grothoff@spec:~/research/taler-bank$ pip3 install . --prefix=/tmp/grothoff --isolated ERROR: Can not combine '--user' and '--prefix' as they imply different installation locations |
|
This has to be a configuration problem. It works from a fresh install: dold@fdold ~> docker run -i -t debian:unstable /bin/bash root@3559332d9aa4:/# apt-get update && apt-get install -y python3-pip python3-setuptools git vim autoconf libpq-dev root@3559332d9aa4:/# git clone git://taler.net/bank root@3559332d9aa4:/# cd bank/ root@3559332d9aa4:/bank# ./bootstrap && ./configure --prefix=/home/foo root@3559332d9aa4:/bank# pip3 install . --prefix=/home/foo [...] Successfully installed django django-simple-math-captcha psycopg2 requests setproctitle talerbank uWSGI validictory |
|
Same for debian:jessie, except that $ pip3 install -U pip must be run first. |
|
Yes, with that magic incantation it works. Needs to be added to README... |
|
So what did you change? I thought that you said above that you ran exactly that command, and it failed? |
|
Running "pip3 install -U pip" first helped... |
|
So this seems fixed then. I've also added a check for pip>=8.1.1. |
Date Modified | Username | Field | Change |
---|---|---|---|
2016-04-07 23:03 | Christian Grothoff | New Issue | |
2016-04-07 23:03 | Christian Grothoff | Status | new => assigned |
2016-04-07 23:03 | Christian Grothoff | Assigned To | => Marcello Stanisci |
2016-04-08 11:17 | Marcello Stanisci | Note Added: 0010413 | |
2016-04-08 11:56 | Florian Dold | Note Added: 0010415 | |
2016-04-08 17:10 | Florian Dold | Status | assigned => resolved |
2016-04-08 17:10 | Florian Dold | Resolution | open => fixed |
2016-04-08 17:10 | Florian Dold | Assigned To | Marcello Stanisci => Florian Dold |
2016-04-08 20:42 | Christian Grothoff | Status | resolved => closed |
2016-04-08 20:42 | Christian Grothoff | Fixed in Version | => 0.0 |
2016-04-08 21:22 | Christian Grothoff | Note Added: 0010417 | |
2016-04-08 21:22 | Christian Grothoff | Status | closed => assigned |
2016-04-08 21:28 | Christian Grothoff | Note Added: 0010418 | |
2016-04-08 21:30 | Christian Grothoff | Note Added: 0010419 | |
2016-04-08 21:31 | Christian Grothoff | Priority | high => immediate |
2016-04-08 21:31 | Florian Dold | Note Added: 0010420 | |
2016-04-08 21:34 | Florian Dold | Note Added: 0010421 | |
2016-04-08 21:37 | Florian Dold | Note Added: 0010422 | |
2016-04-08 21:37 | Christian Grothoff | Note Added: 0010423 | |
2016-04-08 21:37 | Christian Grothoff | Note Added: 0010424 | |
2016-04-08 21:39 | Florian Dold | Note Added: 0010425 | |
2016-04-08 21:40 | Florian Dold | Note Edited: 0010425 | |
2016-04-08 21:43 | Christian Grothoff | Note Added: 0010426 | |
2016-04-08 21:52 | Florian Dold | Note Added: 0010427 | |
2016-04-08 21:55 | Florian Dold | Note Added: 0010428 | |
2016-04-08 22:25 | Florian Dold | Note Added: 0010429 | |
2016-04-08 23:01 | Florian Dold | Note Added: 0010430 | |
2016-04-08 23:01 | Florian Dold | Status | assigned => feedback |
2016-04-09 00:01 | Christian Grothoff | Note Added: 0010431 | |
2016-04-09 00:01 | Christian Grothoff | Status | feedback => assigned |
2016-04-09 01:06 | Florian Dold | Note Added: 0010432 | |
2016-04-09 01:08 | Florian Dold | Note Added: 0010433 | |
2016-04-09 01:11 | Christian Grothoff | Note Added: 0010434 | |
2016-04-09 01:12 | Florian Dold | Note Added: 0010435 | |
2016-04-09 01:17 | Christian Grothoff | Note Added: 0010436 | |
2016-04-09 01:44 | Florian Dold | Note Added: 0010437 | |
2016-04-09 01:44 | Florian Dold | Status | assigned => resolved |
2016-04-09 01:50 | Christian Grothoff | Status | resolved => closed |
2022-08-23 20:26 | Christian Grothoff | Category | bank (demonstrator) => py bank (demonstrator, obsolete) |
2023-12-03 01:23 | Christian Grothoff | Category | py bank (demonstrator, obsolete) => obsolete componet |
2023-12-11 20:08 | Florian Dold | Category | obsolete componet => obsolete component |