I am trying to install pyjnius, & when i execute simple program it shows following error..
How do i solve it?
SystemError: Error calling dlopen(/usr/lib/jvm/java-7-openjdk/jre/lib/amd64 /server/libjvm.so: /usr/lib/jvm/java-7-openjdk/jre/lib/amd6h file or directory
Pyjnius depends on Cython and Java. Assuming that you already have Java installed. Please do the following:
su
pip install cython
pip install pyjnius
Example
Related
I am one of the devs of a (fairly large) C++ simulation tool. Disclaimer : I'm more of a physicist than a dev. I wrote Python bindings for that project using pybind11.
I managed to get the Python module to compile with cmake. I then managed to write a setup.py file using skbuild that does compile the Python module :
python3 setup.py sdist bdist_wheel
In _skbuild/linux-x86_64-3.9/cmake-build/lib/ (and in the tar archive dist/cytosim-0.0.0.tar.gz) there is indeed a compiled library : cytosim.cpython-39-x86_64-linux-gnu.so.
However, when I want to install the module :
pip3 install dist
I get an error :
gcc: error: src/py3/dist.c: No such file or directory
I am very confused because I do not have an directory called py3 in src.
Any pointer ? Anything I'm doing wrong ? Thanks !
The command
pip3 install dist
tries (and fails) to install the dist package from the pypi repository.
Maybe try
pip3 install dist/cytosim-0.0.0.tar.gz
instead.
I try to install the python package using the following command line in anacondaprompt:
(base) C:\Users\Lenovo>pip install -r D:\autoencoder\Website_by_python\requirements.txt
Then the error is shown as
Processing c:\tmp\build\80754af9\backports.functools_lru_cache_1618170165463\work
ERROR: Could not install packages due to an OSError: [Errno 2] No such file or directory: 'C:\\tmp\\build\\80754af9\\backports.functools_lru_cache_1618170165463\\work'
I don't really know how to deal with that error. Could you please tell me?
Could not install packages due to an OSError
is always related to administrator privileges or even worse the python version that visual studio installs by default i suggest you to
uninstall python
delete the python extension from vs code
delete the python version in the data folder you can access it by run %temp% and in the address bar click on app data from there look for python
finally reinstall python i suggest you directly to C: without any version numbers i.e c:/Python dont forget to click add variables to path then open visual studio again and let him install the python extension again
omg i just noticed you talk about anaconda nevertheless it should be exactly the same problem
I'm using Python 3.10.4. I'm trying to work on a Django project, but when I create a Virtualenv then installing the package is not working.
PS C:\Users\schad\Desktop\importExport> & c:/Users/schad/Desktop/importExport/env/Scripts/Activate.ps1
(env) PS C:\Users\schad\Desktop\importExport> pip install django-import-export
Fatal error in launcher: Unable to create process using '"C:\Users\schad\Desktop\env\Scripts\python.exe" "C:\Users\schad\Desktop\importExport\env\Scripts\pip.exe" install django-import-export': The system cannot find the file specified.
(env) PS C:\Users\schad\Desktop\importExport> pip install mysqlclient
Fatal error in launcher: Unable to create process using '"C:\Users\schad\Desktop\env\Scripts\python.exe" "C:\Users\schad\Desktop\importExport\env\Scripts\pip.exe" install mysqlclient': The system cannot find the file specified.
(env) PS C:\Users\schad\Desktop\importExport>
It's weird, the terminal trying to using
C:\Users\schad\Desktop\env\Scripts\python.exe
but it should be
C:\Users\schad\Desktop\importExport\env\Scripts\pip.exe,
Could you try to switch the python interpreter to another one? And please check whether you have configured something in your settings.json file although this should be stored in the storage under C:\Users\{UserName}\AppData\Roaming\Code\User folder.
You can try to switch to another python interpreter and then switch back, if it still does not work you can delete state.vscdb under C:\Users\{UserName}\AppData\Roaming\Code\User\globalStorage folder.
I'm using the "import ldap" in a python code. This is on a windows 10 machine.
I installed the python-ldap module
pip3 install python-ldap
Installed the dependencies based on the instructions at Python Can't install packages
Also resolved all the pip deployment issues based on Installing python-ldap in a virtualenv on Windows
I'm now getting the following error when executing the import ldap statement. am I missing something here? Any ideas to resolve it?
thon39\site-packages\ldap\__init__.py", line 34, in <module>
import _ldap
ImportError: DLL load failed while importing _ldap: The specified module could not be found.
Visit the unofficial Python binaries page:
https://www.lfd.uci.edu/~gohlke/pythonlibs/#python-ldap
Download the appropriate WHL package for your system.
For example, if you're using Python 3.8 on an x64 system, download python_ldap‑3.3.1‑cp38‑cp38‑win_amd64.whl
(hint: do NOT download the +sasl version unless you have the Cyrus SASL code running on your system...)
Start the VirtualEnv for your project, if you're using one (C:\Users\youruser\.virtualenv\YourVirtualEnv\Scripts\activate.bat) -- if you're not, skip this step.
Then run pip3 install C:\Path\To\python_ldap_x.x.x-cpXX-cpXX-winXX.whl and this should install the Python DLL (pyd) file for you.
I am trying to build a Python library Healpy. My first try was to use pip. After typing:
>pip install --user healpy
i got result:
>checking if library 'cfitsio' is installed
>error: No such file or directory
After that i tried to build library on my own - i downloded the sources and builded cfitsio using commands:
>/.configure
>make
>make install
after doing that i got a libcfitsio.a file, pkg-config folder with .pc file and some .h files in include folder. But after typing:
> python setup.py install
i got the same error. I got the same error after building lib in Windows. Did anyone have similar problem ? I would be very greateful for any suggestions.
As mentioned in the healpy INSTALL documentation you must specify the PKG_CONFIG_PATH environment variable if you want to use external cfitsio or healpix modules:
PKG_CONFIG_PATH=/path/to/local/lib/pkgconfig
Note: adapt with your own path obtain from the cfitsio compilation process!
Then you shall be able to run the compilation of healpy...