pywin32 RuntimeError: Can't find the Windows SDK - python

Execute "python setup3.py install" reported this error
I am searching for a long time on net. But no use. Please help or try to give some ideas how to achieve this.
D:\Software Package\pywin32-master\pywin32-master>python setup3.py install
Converting...
Executing...
Building pywin32 3.6.221.0
Traceback (most recent call last):
File "setup3.py", line 16, in <module>
exec(str(got))
File "<string>", line 305, in <module>
RuntimeError: Can't find the Windows SDK
D:\Software Package\pywin32-master\pywin32-master>python setup.py install
File "setup.py", line 127
print "Building pywin32", pywin32_version
^
SyntaxError: Missing parentheses in call to 'print'

Related

find_package() errors during installing package via pip

I'm tring to install django-dbsettings with pip but it causes the following error:
Downloading django-dbsettings-0.7.4.tar.gz
Running setup.py egg_info for package django-dbsettings
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "/path/virtualenv/build/django-dbsettings/setup.py", line 23, in <module>
packages=find_packages(include=['dbsettings']),
TypeError: find_packages() got an unexpected keyword argument 'include'
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "/path/virtualenv/build/django-dbsettings/setup.py", line 23, in <module>
packages=find_packages(include=['dbsettings']),
TypeError: find_packages() got an unexpected keyword argument 'include'
Also I'm using pip 1.0 and python 2.7.
How can I fix it?
There is no include keyword in find_packages() using older versions of setuptools, you need to upgrade:
pip install -U setuptools
I would also update pip.

Error installing python preppy

When installing preppy in a virtualenv on my workstation (Ubuntu Linux) it works, but when installing it the same way on an instance of Amazon Linux I get an error like this:
(env)[ec2-user#server t]$ pip install preppy
Downloading/unpacking preppy
Downloading preppy-2.3.2.tar.gz (42kB): 42kB downloaded
Running setup.py (path:/home/ec2-user/t/env/build/preppy/setup.py) egg_info for package preppy
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/home/ec2-user/t/env/build/preppy/setup.py", line 13, in <module>
import preppy
File "/home/ec2-user/t/env/build/preppy/preppy.py", line 72, in <module>
isPy3 = sys.version_info.major == 3
AttributeError: 'tuple' object has no attribute 'major'
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "/home/ec2-user/t/env/build/preppy/setup.py", line 13, in <module>
import preppy
File "/home/ec2-user/t/env/build/preppy/preppy.py", line 72, in <module>
isPy3 = sys.version_info.major == 3
AttributeError: 'tuple' object has no attribute 'major'
----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /home/ec2-user/t/env/build/preppy
Storing debug log for failure in /home/ec2-user/.pip/pip.log
This hints at a problem when checking what the Python version is, but googling around did not help me this time.
I'm aware that python packages sometimes have dependencies on host software, eg to install psycopg2 I had to first install the Postgres development packages on the operating system.
So how do I fix this error?
Your ec2 instance needs to be running (at least) Python 2.7.
sys.version_info didn't become a named tuple until 2.7.

Error installing ckanclient on Python 3.3 using pip

I'm trying to install ckanclient on Python 3.3 using pip. The command line I'm using is:
c:\Python33\Scripts>pip install ckanclient
I'm getting:
Downloading/unpacking ckanclient
Downloading ckanclient-0.10.tar.gz
Running setup.py (path:c:\users\lgms\appdata\local\temp\pip_build_lgms\ckanclient\setup.py) egg_info for package ckanclient
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "c:\users\lgms\appdata\local\temp\pip_build_lgms\ckanclient\setup.py"
, line 8, in <module>
from ckanclient import __version__, __description__, __long_description_
_, __license__
File ".\ckanclient\__init__.py", line 100
except HTTPError, inst:
^
SyntaxError: invalid syntax
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "c:\users\lgms\appdata\local\temp\pip_build_lgms\ckanclient\setup.py", li
ne 8, in <module>
from ckanclient import __version__, __description__, __long_description__, _
_license__
File ".\ckanclient\__init__.py", line 100
except HTTPError, inst:
^
SyntaxError: invalid syntax
----------------------------------------
Cleaning up...
I need a clue about what is happening there and how to fix it. My OS is Windows 7 Pro, I'm using the standard Python distribution (I also have Anaconda Python installed, but this doesn't look like a version conflict).
The full error log is in: http://pastebin.com/NgFFCrcK
ckanclient, as well as CKAN itself, is not compatible with Python 3. You'll need 2.7.
Another hint: ckanclient is deprecated, see https://github.com/okfn/ckanclient-deprecated. However, if for some reason you really need it please do not use the rather old pip (e.g. pypi) version, but the up-to-date one from github.

pip install rauth fails : syntax error

I just installed Python 3.3 and then I tried to install rauth by issuing the command:
pip install rauth
and I get this error:
Downloading/unpacking rauth
Running setup.py egg_info for package rauth
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "c:\users\pipul\appdata\local\temp\pip-build-pipul\rauth\setup.py", l
ine 4, in <module>
from rauth import __version__
File ".\rauth\__init__.py", line 30, in <module>
from .service import OAuth1Service, OAuth2Service, OflyService
File ".\rauth\service.py", line 23
except KeyError, e: # pragma: no cover
^
SyntaxError: invalid syntax
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "c:\users\pipul\appdata\local\temp\pip-build-pipul\rauth\setup.py", line 4, in <module>
from rauth import __version__
File ".\rauth\__init__.py", line 30, in <module>
from .service import OAuth1Service, OAuth2Service, OflyService
File ".\rauth\service.py", line 23
except KeyError, e: # pragma: no cover
^
SyntaxError: invalid syntax
----------------------------------------
Command python setup.py egg_info failed with error code 1 in c:\users\pipul\appd
ata\local\temp\pip-build-pipul\rauth
Storing complete log in C:\Users\pipul\pip\pip.log
## Heading ##c:\Python33\Scripts>
Similarly installing oauth2 also fails. But installing selenium succeeds.
Now what could be the thing that is causing this failure?
Thanks in advance.
Like many packages, rauth currently does not support Python 3. However, it looks like there is a branch where they are working on it. See here.
In general, you may have more luck installing packages if you use Python 2.7.

problem running scons

I am trying to get started with scons. I have Python 3.0.1 and downloaded Scons 1.2.0; when I try to run scons I get the following error. Am I doing something wrong here?
C:\tmp\scons>c:\appl\python\3.0.1\Scripts\scons
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "c:\appl\python\3.0.1\Lib\site-packages\scons-1.2.0\SCons\__init__.py", l
ine 43, in <module>
import SCons.compat
File "c:\appl\python\3.0.1\Lib\site-packages\scons-1.2.0\SCons\compat\__init__
.py", line 208
raise Error, "Cannot move a directory '%s' into itself '%s'." % (src, dst)
^
SyntaxError: invalid syntax
That's Python 2 syntax. I assume scons doesn't run on Python 3. You need to run it using Python 2.

Categories