Coder Social home page Coder Social logo

Comments (6)

csadorf avatar csadorf commented on June 3, 2024 1

Thank you for reporting. We will have to evaluate whether we "officially support" editable installs, but it would certainly be desirable.

from aiidalab-docker-stack.

mbercx avatar mbercx commented on June 3, 2024

Hmm, I think I've actually been doing this. In which environment was this? The root or the aiida (base)?

As a sidenote: it would be nice if the apps that ship by default are actually installed in editable mode. Makes it easier to start developing. 😁

from aiidalab-docker-stack.

csadorf avatar csadorf commented on June 3, 2024

As a sidenote: it would be nice if the apps that ship by default are actually installed in editable mode. Makes it easier to start developing. 😁

Apps are just a set of notebooks so they are installed by being placed within the apps/ directory. This means they are essentially installed "editable" by default. This concerns the app dependencies which we generally don't want to install in editable mode.

from aiidalab-docker-stack.

mbercx avatar mbercx commented on June 3, 2024

This means they are essentially installed "editable" by default.

You're right, my bad. The "editable" install I had to do was for the aiidalab-qe-workchain. :)

from aiidalab-docker-stack.

ltalirz avatar ltalirz commented on June 3, 2024

I confirm this issue

(base) aiida@1d12ef3a1eb7:~/pgsu$ pip install -e .
Defaulting to user installation because normal site-packages is not writeable
Obtaining file:///home/aiida/pgsu
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Requirement already satisfied: click in /opt/conda/lib/python3.7/site-packages (from pgsu==0.2.1) (7.1.2)
Requirement already satisfied: psycopg2-binary>=2.8.3 in /opt/conda/lib/python3.7/site-packages (from pgsu==0.2.1) (2.8.6)
Installing collected packages: pgsu
  Running setup.py develop for pgsu
    ERROR: Command errored out with exit status 1:
     command: /opt/conda/bin/python3.7 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/home/aiida/pgsu/setup.py'"'"'; __file__='"'"'/home/aiida/pgsu/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' develop --no-deps --user --prefix=
         cwd: /home/aiida/pgsu/
    Complete output (28 lines):
    running develop
    WARNING: The user site-packages directory is disabled.
    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: '/opt/conda/lib/python3.7/site-packages/test-easy-install-3443.write-test'

    The installation directory you specified (via --install-dir, --prefix, or
    the distutils default setting) was:

        /opt/conda/lib/python3.7/site-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://setuptools.readthedocs.io/en/latest/deprecated/easy_install.html

    Please make the appropriate changes for your system and try again.

    ----------------------------------------
ERROR: Command errored out with exit status 1: /opt/conda/bin/python3.7 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/home/aiida/pgsu/setup.py'"'"'; __file__='"'"'/home/aiida/pgsu/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' develop --no-deps --user --prefix= Check the logs for full command output.

At first, it looks like pip realizes what it should do (Defaulting to user installation because normal site-packages is not writeable) but then it still ends up trying to write to the system directory.

It turns out that this pip issue is known since April 2020 and still not fixed.

For packages that don't use the pyproject.toml, you can work around it for the moment by using pip install --no-use-pep517 -e ..
For those that do, you'll need to do a manual fix, e.g. like here.

from aiidalab-docker-stack.

danielhollas avatar danielhollas commented on June 3, 2024

This issue is no longer present in the new docker stack, since pip can install into the system-wide environment under jovyan user.

CC @yakutovicha @unkcpz

from aiidalab-docker-stack.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.