Giter Site home page Giter Site logo

permissions error about itea HOT 11 CLOSED

folivetti avatar folivetti commented on September 15, 2024
permissions error

from itea.

Comments (11)

folivetti avatar folivetti commented on September 15, 2024

could you patch the itea.py locally and change line 108 to

subprocess.call([f"stack run config {cfgname}"], shell=True, cwd=cwd)

and see if it works?
I have just patched this file, so if you redo the install script it should get the correct file. Let me know if it works.

I'm also trying to replicate a conda environment that works with stack without using sudo, but haven't got any luck so far.

from itea.

lacava avatar lacava commented on September 15, 2024

I'm confused, did you want to add --allow-different-user to line 108 or do you want me to remove it?

I reran the install script and get

 bash itea_install.sh 
Cloning into 'ITEA'...
remote: Enumerating objects: 2192, done.
remote: Counting objects: 100% (2192/2192), done.
remote: Compressing objects: 100% (1296/1296), done.
remote: Total 2192 (delta 1011), reused 1886 (delta 726), pack-reused 0
Receiving objects: 100% (2192/2192), 25.76 MiB | 6.88 MiB/s, done.
Resolving deltas: 100% (1011/1011), done.
/home/bill/anaconda3/envs/srbench/bin/stack
Preparing to install GHC (tinfo6) to an isolated location.
This will not interfere with any system-level installation.
Downloaded ghc-tinfo6-8.10.4.                                      
configure: WARNING: Unknown vendor conda                                              
configure: WARNING: Unknown vendor conda
configure: WARNING: Unknown vendor conda
Installed GHC.     
WARNING: Ignoring MissingH's bounds on random (>=1.0.1.1 && <1.2); using random-1.2.0.
Reason: allow-newer enabled.
[1 of 2] Compiling Main             ( /home/bill/.stack/setup-exe-src/setup-mPHDZzAJ.hs, /home/bill/.stack/setup-exe-src/setup-mPHDZzAJ.o )
[2 of 2] Compiling StackSetupShim   ( /home/bill/.stack/setup-exe-src/setup-shim-mPHDZzAJ.hs, /home/bill/.stack/setup-exe-src/setup-shim-mPHDZzAJ.o )
Linking /home/bill/.stack/setup-exe-cache/x86_64-linux-tinfo6/tmp-Cabal-simple_mPHDZzAJ_3.2.1.0_ghc-8.10.4 ...
/home/bill/anaconda3/envs/srbench/bin/../lib/gcc/x86_64-conda-linux-gnu/7.5.0/../../../../x86_64-conda-linux-gnu/bin/ld: cannot find -lgmp
collect2: error: ld returned 1 exit status
`x86_64-conda-linux-gnu-cc' failed in phase `Linker'. (Exit code: 1)

--  While building simple Setup.hs (scroll up to its section to see the error) using:
      /home/bill/.stack/programs/x86_64-linux/ghc-tinfo6-8.10.4/bin/ghc-8.10.4 -rtsopts -threaded -clear-package-db -global-package-db -hide-all-packages -package base -main-is StackSetupShim.mainOverride -package Cabal-3.2.1.0 /home/bill/.stack/setup-exe-src/setup-mPHDZzAJ.hs /home/bill/.stack/setup-exe-src/setup-shim-mPHDZzAJ.hs -o /home/bill/.stack/setup-exe-cache/x86_64-linux-tinfo6/tmp-Cabal-simple_mPHDZzAJ_3.2.1.0_ghc-8.10.4
    Process exited with code: ExitFailure 1

from itea.

folivetti avatar folivetti commented on September 15, 2024

I'm confused, did you want to add --allow-different-user to line 108 or do you want me to remove it?

I meant to replace line 108 with the one I posted. But it doesn't matter, by rerunning the installation script this is solved.

Now the problem is that it cannot find gmp inside the conda environment.

I'm simulating this issue in a sandbox environment, but I couldn't find a solution that didn't involve the use of sudo to install the necessary libs. I'm still investigating alternatives, but one (ugly) possibility would be to provide a precompiled binary together with the libraries in the same directory.

from itea.

folivetti avatar folivetti commented on September 15, 2024

@lacava is it ok to provide a compiled executable file? In order to run in your environment, it would require to add the following in your environment.yml (I can make a pull request, if you like):

  - libblas=3.9.0=8_openblas
  - liblapack=3.9.0=8_openblas
  - gmp=6.2.1=h58526e2_0
  - gsl=2.6=he838d99_2
  - libffi=3.3=h58526e2_2

and in your install.sh script insert right after line 4:

export LD_LIBRARY_PATH=~/.conda/envs/srbench/lib:$LD_LIBRARY_PATH

I'm assuming srbench env will be under home directory.

If that's ok to you, I can compile the binary and change the python wrapper and installation scripts accondingly.

from itea.

lacava avatar lacava commented on September 15, 2024

i'm fine with it! Just need something that A) works on github actions and B) will install in the HPC environment i'm running the experiments in.

from itea.

folivetti avatar folivetti commented on September 15, 2024

@lacava great! I just need to know if the HPC runs under the same OS as github actions (Ubuntu 20). The main thing is what is the GLIBC version I need to compile with (the output of ldd --version)

from itea.

lacava avatar lacava commented on September 15, 2024

from itea.

lacava avatar lacava commented on September 15, 2024

from itea.

folivetti avatar folivetti commented on September 15, 2024

done! I'm making a PR into srbench that should fix everything related to ITEA. If you find any problem, please reopen this issue.
Thanks for the input!

from itea.

lacava avatar lacava commented on September 15, 2024

Great. One note:

I'm assuming srbench env will be under home directory.

You should be able to use the $CONDA_PREFIX environment variable to point to the environment location

from itea.

folivetti avatar folivetti commented on September 15, 2024

Yes, I'm using that now :-)
See the PR comments, I had to add a line in configure.sh so that I can actually use this variable. It passed on the CI of my fork.

from itea.

Related Issues (7)

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.