'pip install pyqt5-tools error subprocess-exited-with-error

im installing pyqt5 tools and this happens

C:\Users\Jansen>pip install pyqt5-tools
Collecting pyqt5-tools
  Using cached pyqt5_tools-5.15.4.3.2-py3-none-any.whl (29 kB)
  Using cached pyqt5_tools-5.15.4.3.1-py3-none-any.whl (28 kB)
  Using cached pyqt5_tools-5.15.4.3.0.3-py3-none-any.whl (28 kB)
  Using cached pyqt5_tools-5.15.3.3.2-py3-none-any.whl (29 kB)
  Using cached pyqt5_tools-5.15.3.3.1-py3-none-any.whl (28 kB)
  Downloading pyqt5_tools-5.15.3.3.0.3-py3-none-any.whl (28 kB)
  Downloading pyqt5_tools-5.15.2.3.2-py3-none-any.whl (29 kB)
Collecting python-dotenv
  Using cached python_dotenv-0.20.0-py3-none-any.whl (17 kB)
Collecting pyqt5==5.15.2
  Downloading PyQt5-5.15.2.tar.gz (3.3 MB)
     ---------------------------------------- 3.3/3.3 MB 6.9 MB/s eta 0:00:00
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... error
  error: subprocess-exited-with-error`  

im trying to install pyqt5 so that i can use the pyuic5 command



Solution 1:[1]

As I can't yet comment questions, may I ask: are you using a virtual environment? Anyway, you could try with this command:

pip install pyqt5-tools~=5.15

Moreover, as @musicamante said, if you're using a Python version that's above 3.10, a downgrade to version 3.9 or older is recommended as pyqt tools ar still not compatible with >3.9 versions. However, as I've seen here, you can try installing an specific 5.15 release version, so please try:

pip install PyQt5==5.15.5

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1