Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PyWinAuto installation failing on Python 3.12 #1368

Open
manju1847 opened this issue Jan 11, 2024 · 5 comments
Open

PyWinAuto installation failing on Python 3.12 #1368

manju1847 opened this issue Jan 11, 2024 · 5 comments

Comments

@manju1847
Copy link

Expected Behavior

PyWinAuto installation should report success on Python 3.12

Actual Behavior

PyWinAuto installation fails on Python 3.12

Steps to Reproduce the Problem

Here are the steps/commands that I used to install on Python 3.12. I am using PyWinAuto from atspi branch. I am able to install the same version without any issues on Python 3.8 and Python 3.10.

D:\softwares\Python12>python --version
Python 3.12.1

D:\softwares\Python12>pip list
Package Version


comtypes 1.2.1
pip 23.2.1
pywin32 306
six 1.16.0

D:\softwares\Python12>pip install d:\softwares\PyWinAuto\pywinauto-atspi
Processing d:\softwares\pywinauto\pywinauto-atspi
Installing build dependencies ... error
error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> [7 lines of output]
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001F765B5C8C0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001F764656810>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001F765D37350>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001F765D37680>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000001F765D378C0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
ERROR: Could not find a version that satisfies the requirement setuptools>=40.8.0 (from versions: none)
ERROR: No matching distribution found for setuptools>=40.8.0
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

Short Example of Code to Demonstrate the Problem

Specifications

  • Pywinauto version: PyWinAuto atspi 0.6.8
  • Python version and bitness: Python 3.12.1
  • Platform and OS: Windows 10
@manju1847
Copy link
Author

Machine on which I am installing is not having outbound connection to internet. So I am installing from the disk providing the path to the package. Same approach on same machine is working with Python 3.8 and Python 3.10. But when I move to Python 3.12 this issue pops up.

@junkmd
Copy link
Contributor

junkmd commented Jan 11, 2024

Have you tried pip install --upgrade setuptools?

@manju1847
Copy link
Author

Yes. Installed latest setuptools. Still I see the same error.

D:\softwares\Python12>pip install d:\softwares\Python12\setuptools-69.0.3-py3-none-any.whl
Processing d:\softwares\python12\setuptools-69.0.3-py3-none-any.whl
Installing collected packages: setuptools
Successfully installed setuptools-69.0.3

D:\softwares\Python12>pip list
Package Version


comtypes 1.2.1
pip 23.2.1
pywin32 306
setuptools 69.0.3
six 1.16.0

D:\softwares\Python12>pip install d:\softwares\PyWinAuto\pywinauto-atspi
Processing d:\softwares\pywinauto\pywinauto-atspi
Installing build dependencies ... error
error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> [7 lines of output]
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000002698263EE70>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x00000269825152B0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000002698263F5F0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000002698263F9E0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x000002698263FBC0>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')': /simple/setuptools/
ERROR: Could not find a version that satisfies the requirement setuptools>=40.8.0 (from versions: none)
ERROR: No matching distribution found for setuptools>=40.8.0
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

@manju1847
Copy link
Author

Same error can be reproduced even with Python 3.11.7. Just FYI

@junkmd
Copy link
Contributor

junkmd commented Jan 15, 2024

I have successfully installed pywinauto==0.6.8 in a virtual environment created with Python 3.11.7 and pipenv.

I see from your process that you are probably trying to install the contents of the atspi branch that you downloaded from the repository.

However, since I don't know whether the problem is caused by pip or setuptools or the pywinauto codebase, please check if you can pip install pywinauto==0.6.8 first.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants