PySide and Python3.6 using Anaconda

Hi folks! Today it’s about getting PySide and Python3.6 to work together using Anaconda.

Python3.6Intro

In my last post I welcomed you to my blog. I already thought about writing a little How-To on getting PySide working together with Python 3.6. We will do this using Anaconda and on a Windows10 machine. This would be the simplest setup for this. If you want to know how to do this on a Linux machine or even a RaspberryPi (Raspbian), feel free to leave a comment and I will create a follow-up about it!

When you need to use PySide together with Python3.6 (anything newer than 3.4 in fact) you will definitely run into trouble. This is because PySide was developed depending on Qt4. Python changed to Qt5 though. When googling about it, one of the first links you probably ran across is from Stackoverflow. That one didn’t help me too much, when I had to do this. Therefore I created this post!

About Anaconda

I will update this post to be a bit more detailed and include some info about ‘Conda. For the impatient, I wrote a very short summary of the steps to take. Just read on

Step-by-step guide

Follow this 6 simple steps and you are ready to go:

  1. Download and Install Anaconda with Python3 here (opens in new tab).
  2. Install Anaconda and start the Anaconda Navigator
  3. Create a new Python3-Environment:
    1.  Click on Environment in the Anaconda Navigator
    2. Click on create 
    3. Give the environment an name and make sure you have Python 3.6 (or newer) selected 
    4. Creating the environment will take a moment
  4. Select your newly created environment and open a terminal with it
    1. Click on the “play”-Button and choose “open Terminal” 
  5. Get PySide from conda-forge enteringconda install -c conda-forge pyside in the freshly opened terminal
  6. Accept installing the listed dependecies (by hitting ‘y’ – enter) 
  7. Use whatever module you needed PySide and Python3.6 for 🙂

It is incredibly easy and done in 10 minutes if you know what to do. I needed like days to figure this out.
Is everything working fine for you or do you have any questions? Please contact me, so I can see if I’m able to help you.

 

Over and out

Chrisys

2 thoughts on “PySide and Python3.6 using Anaconda”

  1. THanks, though it doesn’t seem to work any more. I get conflicts:

    UnsatisfiableError: The following specifications were found to be incompatible with each other:

    UnsatisfiableError: The following specifications were found to be incompatible with each other:

    Package vs2015_runtime conflicts for:
    python=3.6 -> vs2015_runtime
    Package libxslt conflicts for:
    pyside -> libxslt
    Package vc conflicts for:
    python=3.6 -> vc[version=’14.*|>=14,=14.1, vc[version=’10.*|14.*|9.*|14|9′]
    Package pip conflicts for:
    python=3.6 -> pip
    Package qt conflicts for:
    pyside -> qt=4.8
    Package sqlite conflicts for:
    python=3.6 -> sqlite[version=’>=3.25.3,=3.26.0,=3.29.0,<4.0a0']

Leave a Reply

Your email address will not be published.