I am having problems trying to install PyGObject on a mac:
Collecting PyGObject
Using cached pygobject-2.28.3.tar.bz2
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/pb/4p0s32g54dl1vg3s25kch71w0000gn/T/pycharm-packaging/PyGObject/setup.py", line 272
raise SystemExit, 'ERROR: Nothing to do, gio could not be found and is essential.'
^
SyntaxError: invalid syntax
The Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/pb/4p0s32g54dl1vg3s25kch71w0000gn/T/pycharm-packaging/PyGObject/
This is what I get back. I have Python 3 and I use PyCharm. I tried to install PyGObject and I can not make it work. I have tried several approaches but nothing has worked. Can someone help me please?
Related
I am trying to install turtle package in pycharm, but while installing i got this error:
Collecting turtle
Using cached turtle-0.0.2.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\Ptr\AppData\Local\Temp\pycharm-packaging\turtle\setup.py", line 40
except ValueError, ve:
except ValueError, ve:
^
SyntaxError: invalid syntax
----------------------------------------
Command "python setup.py egg_info" failed with error code 1
I don't know what to do, help me please.
pip installs turtle 0.0.2 from PyPI. Released in 2009. The code is obviously Python2-only.
You don't need to install turtle — it's a module from the standard library since at least Python 2.6. Just import it and use.
I am trying to install python module turtle to my Ren'Py game. However, it will not install even if I clean the cache and download a fresh version of turtle:
pip install --target game/python-packages turtle
Collecting turtle
Downloading https://files.pythonhosted.org/packages/ff/f0/21a42e9e424d24bdd0e509d5ed3c7dfb8f47d962d9c044dba903b0b4a26f/turtle-0.0.2.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/np/9134zq452dj8pt6435_dqb6h0000gn/T/pip-install-lzh_pa9s/turtle/setup.py", line 40
except ValueError, ve:
^
SyntaxError: invalid syntax
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/np/9134zq452dj8pt6435_dqb6h0000gn/T/pip-install-lzh_pa9s/turtle/
The syntax except ValueError, ve: is Python2-syntax and you're installing the module with Python3. The module was not updated since 2009, it's certainly Python2-only.
The actual module turtle is a part of the standard library, you don't need to install it, it must always be available.
I am trying to install IMDbPY on my MacBook running on 10.12.4 with python version 3.5.2. I did find a couple of question threads addressing the issue but the suggestions offered do not seem to help me.
Following are the outputs from my terminal.
host-vlth5x-205:IMDbPY-3.5 apple$ pip install IMDbPY
Collecting IMDbPY
Using cached IMDbPY-5.1.1.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/gd/f_5prpbn13j_xy22k_4nlvgh0000gn/T/pip-build-k_hgg84y/IMDbPY/setup.py", line 200
print 'Created locale for: %s.' % ' '.join(languages)
^
SyntaxError: invalid syntax
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/gd/f_5prpbn13j_xy22k_4nlvgh0000gn/T/pip-build-k_hgg84y/IMDbPY/
Post this, I have tried downloading the latest stable version of IMDbPY-3.5 here and installing the package manually via the terminal, which gave me the following error:
host-vlth5x-205:IMDbPY-3.5 apple$ python setup.py
File "setup.py", line 128
except SystemExit, e:
^
SyntaxError: invalid syntax
Please help me figure this out. Thanks!
Currently, IMDbPY is a Python 2.7-only library. It can't (yet) work on Python 3.x.
To fix your problem, install Python 2.7
C:\Users\gaucho-ucsb>pip install tradingWithPython
Collecting tradingWithPython
Using cached tradingWithPython-3.1.0.0.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "c:\users\gaucho~1\appdata\local\temp\pip-build-gshhyv\tradingWithPython\setup.py", line 3, in <module>
import tradingWithPython as twp
File "tradingWithPython\__init__.py", line 6, in <module>
from .lib import extra
File "tradingWithPython\lib\extra.py", line 20
print('\r', self, end='')
^
SyntaxError: invalid syntax
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in
c:\users\gaucho~1\appdata\local\temp\pip-build-gshhyv\tradingWithPython\
I'm trying to install the package tradingWithPython into anaconda but I keep getting this error which I can't figure out. Any help would be great thanks.
I just spoke with the author of the library and it seems that tradingwithPython only installs with Python3. It is not backwards compatible anymore.
I just tried this (because I had the same issue) and it seems to work now.
I have python3 installed on linux. In the python interpreter, I tried
import sqlite3
and got
ImportError: No module named '_sqlite3'
so i installed sqlite with
sudo apt-get install libsqlite-dev
and then recompiled python according to the instructions in the README file:
cd ~/Python-3.4.2;
./configure;
make;
make test;
and during test there was an error saying
[ 97/389] test_sqlite
test_sqlite skipped -- No module named '_sqlite3'
and then when I finished the install and tried to run the same python code, I still got the same ImportError. What am I doing wrong?
---EDIT---
I tried
pip install pysqlite
and got this error, which seems to be an issue between Python2.7 and Python3.4:
Downloading/unpacking pysqlite
Downloading pysqlite-2.6.3.tar.gz (76kB): 76kB downloaded
Running setup.py (path:/tmp/pip_build_plat/pysqlite/setup.py) egg_info for package pysqlite
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/tmp/pip_build_plat/pysqlite/setup.py", line 85
print "Is sphinx installed? If not, try 'sudo easy_install sphinx'."
^
SyntaxError: Missing parentheses in call to 'print'
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/tmp/pip_build_plat/pysqlite/setup.py", line 85
print "Is sphinx installed? If not, try 'sudo easy_install sphinx'."
^
SyntaxError: Missing parentheses in call to 'print'
----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /tmp/pip_build_plat/pysqlite
Storing debug log for failure in /home/plat/.pip/pip.log
After install libsqlite-dev you should install pysqlite
pip install pysqlite