I am trying to install the owlready2 lib in Ubuntu by following the method below but I face a problem.
I updated the system and applications
Installed Python 3 and made it the working version (default)
Installed pip3
Used pip and pip3 to install the owlready2 lib
But I faced the below problem which seems to be a problem with the library package:
error: can't copy './hermit/org/semanticweb/hermiT/hierarchy':
doesn't exist or not a regular file"
Command /usr/bin/python3 -c "import setuptools,
tokenize;file='/tmp/pip_buil
d_root/owlready2/setup.py';exec(compile(getattr(tokenize, 'open',
open)(file ).read().replace('\r\n', '\n'), file, 'exec'))"
install --record /tmp/pip-lq v533ik-record/install-record.txt
--single-version-externally-managed --compile f ailed with error code 1 in /tmp/pip_build_root/owlready2 Storing debug log for failure in
/home/ubuntu/.pip/pip.log
Does anyone have any ideas how to resolve this?
Try to install your package with the following command:
python3 -m pip install -I owlready2
If pip3 does not work, you also install Owlready2 manually : download the sources, then run in a terminal:
cd /path/to/Owlready2
python setup.py build
python setup.py install # as root
Also, that would be a good ide to install pip3 and try to install your package with pip3, commands below:
curl "https://bootstrap.pypa.io/get-pip.py" -o "get-pip.py"
python3 get-pip.py --user
I encountered the same problem.
It seems that the issue might lie in something that was added in version 0.14 (at the time of writing the newest version is 0.19). If the owlready2 version is newer than 0.13 then you will encounter the problem.
I have tested these Python versions - 3.7.3 (works), 3.6.8(works), 3.5.2(works until v0.13), 3.4.3(works until v0.13)
To install version v0.13 of owlready2:
pip install owlready2==0.13
Related
I've installed Python 3.6.4 on Windows 8.1 64-bit.
I have it on system environment variables path as:
C:\Users\myuser\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Python 3.6
The command python works in any location with command line so the path works.
Here's the problem:
As I type pip install pymssql in Powershell I get the following error message:
Command "c:\users\myuser\appdata\local\programs\python\python36\python.exe -u -c
"import setuptools, tokenize;__file__=
'C:\\Users\\myuser\\AppData\\Local\\Temp\\pip-build-20pjis7d\\pymssql\\setup.py';
f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f
.close();exec(compile(code, __file__, 'exec'))"
install --record C:\Users\myuser\AppData\Local\Temp\pip-myeuf_lm-record\install-record.txt
--single-version-externally-managed --compile"
failed with error code 1 in C:\Users\myuser\AppData\Local\Temp\pip-build-20pjis7d\pymssql\
Can't find anything with that error message with Google search.
Any ideas what might be the cause of this?
Best practice is to use virtualenv rather than installing into your global environment. virtualenv will also automatically pull in the latest setuptools.
pip install virtualenv
virutalenv my_venv
source my_venv/bin/activate
pip install pymysql
Also make sure that you meet the installation requirements outlined here: http://pymysql.readthedocs.io/en/latest/user/installation.html
You may need to install MySQL server or MariaDB
With Mac 10.13.2,PyCharm 2017.3(community edition),Python 3.6.4:
I've been searching high and low but with no luck as whatever I tried didn't work.I have installed Python 3.6 and PyCharm with a success,but it was driving me crazy when I installed the moduletime,PyBluezand openpyxl in the PyCharm.
Can't install time module The answer to the time package is that The time module is part of Python's standard library. It's installed along with the rest of Python, and you don't need to (nor can you!) install it with pip.
The error warning info when I installed the PyBluez module is always the same as follows:
PermissionError: [Errno 13] Permission denied:
'/Users/ringo/Library/Caches/pip/wheels/e7/40/9d/b772a3cf2ca121e87a06eabe9483271816581dec7c772272d3'
When it occurred,I changed to install it in the terminal app with the command sudo pip3 install PyBluez
The error info:
Failed building wheel for PyBluez
Command "/usr/local/opt/python3/bin/python3.6 -u -c "import
setuptools,
tokenize;file='/private/tmp/pip-build-umoukn9i/PyBluez/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-53lcxusy-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/tmp/pip-build-umoukn9i/PyBluez/
Install openpyxl:
After I installed openpyxl in the terminal app with sudo pip3 install openpyxl,I re-open a PyCharm project,but the module isn't in the packege list.When I import openpyxl and run the project, the info ModuleNotFoundError: No module named 'openpyxl'occurs.
If I install it with PyCharm,the error message is the same as that when install PyBluez
How to solve the issues? It requires me to swipe before I can continue so it slows me down... I will be really grateful if you could share some right method that I should look into. Thanks.
Add further infomation:
Cannot import Bluetooth in Python 3 (OSX)With this question asked by Carl Bratt,I found the answer:
This is the closed OS X import issue #108 on GitHub:
http://github.com/karulis/pybluez/issues/108
It's actually quite an old issue.
One thing the author suggested you might do is remove your current
installation and install the GitHub repo using pip:
git clone https://github.com/karulis/pybluez.git
pip install -e pybluez
Another command you can use:
pip3 install --upgrade git+https://github.com/rgov/pybluez.git#egg=pybluez
try to install anaconda3 instead of python itself
https://www.anaconda.com/download/#macos
I'm using anaconda for python
I'm trying to install matplotlib on a raspberry pi with a clean installation of Raspbian Jessie (4.4 at time of writing). I am trying to install matplotlib for Python 2.7.
I keep getting the following error:
command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip-build-HPuMoo/matplotlib/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-l3s1dW-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /tmp/pip-build-HPuMoo/matplotlib
Storing debug log for failure in /home/pi/.pip/pip.log
to complicate things... this doesn't happen when I install other packages (just installed virtualenv without issue) but it DOES happen when I try to upgrade numpy.
In addition, this error occurs when working on the main distribution of Python (/usr/bin/python) or on a virtual environment (/home/pi/Envs/test/bin/python). I am, then, using pip 1.5.6 on the main distribution and 9.0.1 on the virtualenv. both fail. :(
Not sure why I'm having problems with this... considering how widely used matplotlib is (and how loaded with python packages Jessie is), you'd think there would be no issue. hm.
Per this answer by Peter Brittain and Anshuman Chhabra, installing the libpulse-dev and python-dev libraries should solve your problem. As shown on the Debian Packages references, the file lists of these libraries include the required files.
I'm rookie in python, try to install scrapy but here's what python return
Failed building wheel for lxml
here's the full msg.
Command
"C:\Users\sande\AppData\Local\Programs\Python\Python35-32\python.exe
-u -c "import setuptools, tokenize;file='C:\Users\sande\AppData\Local\Temp\pip-build-fisxcup_\lxml\setup.py';f=getattr(tokenize,
'open', open)(file);code=f.read().replace('\r\n',
'\n');f.close();exec(compile(code, file, 'exec'))" install
--record C:\Users\sande\AppData\Local\Temp\pip-qzhtmsde-record\install-record.txt
--single-version-externally-managed --compile" failed with error code 1 in C:\Users\sande\AppData\Local\Temp\pip-build-fisxcup_\lxml\
There's few solution on StackOverflow, tried but still not work.
Here's what I tried
-m pip install wheel
success, but doesn't make any difference.
-m pip install twisted
Fail, here's what python return
error: Unable to find vcvarsall.bat
Failed building wheel for twisted
-m pip install python3-dev
Failed, here's the return
Could not find a version that satisfies the requirement python3-dev (from versions: )
No matching distribution found for python3-dev
I'm running out of idea, please kindly assist, thanks in advance.
From the scrapy website
I dont think your going to have success with python 3 and scrapy.
Python 3 is not supported on Windows. This is because Scrapy core requirement Twisted does not support Python 3 on Windows.
also from the scrapy website you could try installing it using anaconda (there's a py35 install), check this related answer
I appreciate that there are several topics on the pip error code 1 but the solutions haven't worked and the question has ended.
I installed the full Python 3.4 package at work. I tried to use Pip to install the Numpy package but couldn't get past my works proxy. I downloaded Numpy and added the install file path to %PATH% and again tried to install using Pip but now I am getting 'Error Code 1'. I then tried to install the wheel as one Stack Overflow answer had suggested but still get 'Error Code 1'. I have also tried installing various versions of Numpy and successfully installed the latest version of Pip via Pip installer so I know the %PATH% and Pip install is good.
Python Version: 3.4
Pip Version: 7.1.2
Windows 7 64bit
Numpy Version: 1.10.1
Error:
Command "C:\Python34\python.exe - c "import setuptools, tokenize;__file__='C:\\Users\\MC364~1.BRA\\AppData\\Local\\Temp\\pip-2kvveqqk-build\\setup.py';exec(cinouke(getattr(tokenize, 'open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record C:\Users\MC364~1.BRA\AppData\Local\Temp\pip-q_5tj3ef-record\install-record.txt --single-version-externally-managed --compile" failed with error coode 1 in C:\Users\MC364~1.BRA\AppData\Local\Temp\pip-2kvveqqk-build