Git Product home page Git Product logo

Comments (9)

dpryan79 avatar dpryan79 commented on June 2, 2024

Is there a reason you're not using pip install?

from pybigwig.

msbentsen avatar msbentsen commented on June 2, 2024

Mainly just to limit the amount of setup commands needed to install the full package with all dependencies. I also eventually want to push my package as a pypi package, and as far as I understand, setup.py will define the dependencies (please correct me if I am wrong?) and I am not sure if "pip install" will then correctly handle installation of pybigwig during setup.

It is essentially a minor problem since I can also catch it with an exception and write a nice error message if trying to build the package without pybigwig or trying to import pybigwig without being installed - but if possible, I would of course rather like it to be handled automatically.

from pybigwig.

dpryan79 avatar dpryan79 commented on June 2, 2024

All I can say is that this works fine with deepTools using both pip install and python setup.py install, though usually we're using conda to ensure the dependencies are all there to begin with.

from pybigwig.

dpryan79 avatar dpryan79 commented on June 2, 2024

BTW, pip is just using whatever is in setup.py as far as I know.

from pybigwig.

msbentsen avatar msbentsen commented on June 2, 2024

For me, "python setup.py install" for deepTools also does not install dependencies (runs through without error but dependencies numpy/pybigwig etc. are not available), but I agree that conda is probably the way to go. I will find another solution to my setup. Thanks for the quick answers!

from pybigwig.

barrel0luck avatar barrel0luck commented on June 2, 2024

This is the closest issue I found to my problem. I'm unable to install deeptools via pip:
Command "/usr/bin/python2 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-qVY26u/subprocess32/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-mdnPME/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-qVY26u/subprocess32/

or pip3
Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-bidkekxc/pyBigWig/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-nzki5ppf/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-bidkekxc/pyBigWig/

The issue seems to be with instlaling pyBigWig.

Installing via git works (as in there seem to be no errors), but the packages (numpy, pyBigWig, etc) do not get installed and so deeptools does not work.

I really don't like installing via conda, as it's difficult to use via R/ Rstudio... I've never got that working...
(I'm on Fedora 30).

from pybigwig.

barrel0luck avatar barrel0luck commented on June 2, 2024

My problem was solved after installing python2-devel. pip works perfectly after that. Might help others.

from pybigwig.

dpryan79 avatar dpryan79 commented on June 2, 2024

That's a very good hint, the headers in particular are required for C extensions to compile properly with python.

from pybigwig.

barrel0luck avatar barrel0luck commented on June 2, 2024

Yeah you are right cause even this was there in the error message:

gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/include/python2.7 -c _posixsubprocess.c -o build/temp.linux-x86_64-2.7/_posixsubprocess.o
    _posixsubprocess.c:16:10: fatal error: Python.h: No such file or directory
       16 | #include "Python.h"
          |          ^~~~~~~~~~
    compilation terminated.
    error: command 'gcc' failed with exit status 1
    
    ----------------------------------------
Command "/usr/bin/python2 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-PvGCIU/subprocess32/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-MWHpBe/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-PvGCIU/subprocess32/

This must've been a common problem that you've dealt with before. Apologies for adding noise here.

from pybigwig.

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.