tisaconundrum
tisaconundrum

Reputation: 2292

How do I install PyQt4 on Anaconda version 4.3.X

I'm trying to downgrade my current version of PyQt5 to PyQt4 temporarily. However, this command conda install pyqt=4.11 only yields this error.

UnsatisfiableError: The following specifications were found to be in conflict:
  - pyqt 4.11* -> python 2.7*
  - python 3.6*

What can I do to fix this?

Upvotes: 0

Views: 5332

Answers (2)

Jano
Jano

Reputation: 94

Use: conda info pyqt=4

You can see which Python Versions are working. At the moment, the latest Python3 working with pyqt4 is 3.5

Now:

# Create new environment with python 3.5
conda create -n py35_qt4 python=3.5 anaconda

# Activate the new environment
activate py35_qt4

# Remove pyqt5
conda remove pyqt

# Install the PyQt4 package in the new environment
conda install pyqt=4

Upvotes: 6

Senyokbalgul
Senyokbalgul

Reputation: 1102

PyQt4 only works with Python 2, while PyQt5 only work with Python 3. You are probably trying to install PyQt4 in a Python 3 environment. I recommend you to create a new anaconda environment with Python 2 and then install PyQt4.

Upvotes: -1

Related Questions