Search code examples
python-3.xpywin32setup.py

Issues installing pywin32 behind proxy


I am trying to install pywin32 behind a proxy, and therefore I had to use the zip, rather than the .exe file available. I have down this with other packages and they work fine.

PS C:\Users\Michael.Spencer\Downloads\pywin32-221\pywin32-221> py -3 setup3.py build
Converting...
Executing...
Building pywin32 3.6.221.0
Traceback (most recent call last):
File "setup3.py", line 16
    exec(str(got))
File "<string>", line 1944, in <module>
File "<string>", line 594, in __init__

File "C:\Program Files\Python36\lib\ntpath.py", line 75, in join
   path = os.fspath(path)
TypeError: expected str, bytes or os.PathLike object, not NoneType

I have never come across this issue when downloading packages manually. The only issue I can think of is my machine is 64 bit, and maybe the zip file only contains a 32 bit version? However from what I've read, that would result in a different errortype. Any help is appreciated thanks.


Solution

  • An alternate simpler way to install, just re-iterating from the comments, is instead of building from source would be,

    pip install pypiwin32

    and to install in a different directory, for whatever reason,

    pip install --target=[path] pypiwin32 from

    Install a Python package into a different directory using pip?