Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

So, to keep it simple. Ubuntu 12.10 has python 3.2 pre installed and it is linked to "python3". I downloaded python 3.3 and it's command is "python3.3". However, I downloaded pySide for python3 from synaptic. Using "from PySide.QtCore import *" fails on python3.3. BUT, when I ran just "python3" (aka 3.2) everything works fine. Synaptic just installed lib for python3.2 which is default for python3 in ubuntu. How can I force synaptic to install modules for python3.3?


share|improve this question

You can custom your python3 alias. For this, you can modify your .bashrc file by appending "alias python3='python3.3'" at the end of it. This shell script can do it for you :


cd ~

# Create the ~/.bashrc file if it does not exist
if [ ! -f ./.bashrc ]; then
    touch .bashrc
    chmod 755 .bashrc
    echo "#!/bin/bash" >> .bashrc

# Append the customed alias
echo " " >> .bashrc
echo "alias python3='python3.3'" >> .bashrc
echo " " >> .bashrc

# Reload settings in the .bashrc script
source .bashrc
share|improve this answer
Thanks. This will make installing modules from synaptic to python3.3 dir, yes? – user1873947 Dec 16 '12 at 9:34
Well, this indeed makes "python3" run "python3.3", but after installing python3 module from synaptic, it still installs only to python 3.2... There must be some magic with symlinks to 3.3 location. – user1873947 Dec 16 '12 at 10:01
I'm having the same issue, trying to download packages but they default to the wrong installation – ssb Mar 14 '13 at 11:35

You may run different python versions on the same system by setting up the appropriate environment variables. This would allow you to locally install a later version of Python than the synaptic package manager might offer. e.g. in a file (mysetup) have:


export PYTHONPATH=/usr/lib/python2.7/lib-tk:/usr/lib/python2.7/lib-stdwin:/usr/lib/python2.7/lib-dynload:/usr/lib:.     

and put them into your environment with . mysetup

share|improve this answer

Looking at the file list for a pyside package, it appears that it's only been compiled for Python 3.2. You can either:

  • Use 3.2 for now. 3.3 will probably be available with 13.04.
  • Download the source code for pyside (use apt-get source pyside), and recompile it for Python 3.3.
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.