Python is an interpreted programming language that is often, but not solely, used as a scripting language. A version of Python is included by default on all Ubuntu distributions.

learn more… | top users | synonyms

13
votes
4answers
11k views

“Authentication service is not available” when installing IDLE (using python 2.7)

I am getting this error installing IDLE on 12.10: Software can't be installed or removed because the authentication service is not available. (org.freedesktop.PolicyKit.Error.Failed: ...
13
votes
2answers
7k views

How do I install packages with pip when there are multiple Python versions?

I have different versions of python installed, python 2.7 being the default and 3.2 the second. Now I want to install pyramid to the 3.2 installation. How can I do this? Just using pip to install ...
13
votes
1answer
2k views

Putting an arbitrary gtk.Widget into an appindicator.Indicator

Putting any gtk.Widget inside a gtk.Menu works, somewhat, by putting an empty gtk.MenuItem in first. It doesn't seem to be reliable - but it basically works. With an appindicator.Indicator, it doesn't ...
12
votes
4answers
4k views

Writing indicators with Python, GIR and GTK3

I'm writing an application that needs to use an indicator. I've done this in the past using PyGTK and GTK2, using as reference this document: ...
12
votes
6answers
23k views

How do I install Python Pandas?

I'm trying to install Pandas (python package) on Ubuntu. I can't find it in the repos. Is there a package repo for this or do I have to install from source?
12
votes
3answers
27k views

How do I detect and remove Python packages installed via pip?

I have accidently installed Python packages to my system using pip instead of apt-get. I did this in two ways: using an older version of virtualenv, I forgot to append --no-site-packages when ...
12
votes
3answers
4k views

How to use Rhythmbox python console

Maybe this is obvious and I am missing it, or maybe someone's already written a great guide and my (seeming exhaustive) googling is failing to turn it up, but I cannot figure out for the life of me ...
12
votes
2answers
780 views

How to Change Quickly's Editor?

I've just downloaded Ninja IDE and I really like it's interface. Is there a way to configure the Quickly app to launch my project in Ninja IDE when I type quickly edit?
12
votes
1answer
292 views

Promoting an app in the Ubuntu Software Center through a ratings and reviews API

As an app author, I would like to promote my app in Ubuntu. One nice way to do it is to encourage users to submit their reviews and ratings to the Software Center. It would be really cool if I could ...
12
votes
3answers
4k views

How can I install numpy on Python 3.1?

I have Ubuntu 10.10 server on EC2. I installed Python 3.1, and now I want to install NumPy on it. How do I do it? I tried easy_install-3.1 numpy but got this error: RefactoringTool: Refactored ...
11
votes
3answers
16k views

How do I make the terminal run python 3.1?

Currently, when I type "python" at the terminal I get v2.6 which is all fine and dandy but how can I set it to use v3.1 instead? Is there a "path" variable out there somewhere that I can change like ...
11
votes
3answers
303 views

Is there a Perl or Python script I can write which can minimize the Gnome terminal window?

I'm on Ubuntu 14.04 with the old-style GNOME setting from the GDM. (I don't like the new Unity interface.) Is there a way I can create a command that I can type in my terminal window to minimize it? ...
11
votes
4answers
1k views

Why do most GNOME developers prefer Python over Java for GTK+ programming?

I only know C and Java. And I really don't want to learn another language when I can work with what I already know. I haven't ever written a GTK+ application, but I am planning to start with an ...
11
votes
1answer
7k views

What language(s) can I use in LibreOffice for macro scripting?

Not finding any info online; I hope somebody here knows. It was Python in OpenOffice; is it still Python? Or are they moving to gasp VBA?
11
votes
1answer
3k views

How can I get tab-completion in the interactive Python interpreter?

I often use Python 3000's interactive interpreter, but it's missing the convenience of tab-completion I'm used to from ipython, which isn't available for Python 3.x. How do I enable tab completion in ...
11
votes
2answers
835 views

Quickly template for PyQt?

Because I like Qt and Python, is there a Quickly template for PyQt similar to the PyGTK one?
11
votes
1answer
301 views

Show personalized banner exhibits on Ubuntu Software Center

How can I show my own personalized banner exhibits on Ubuntu Software Center? I've seen some URL definitions on /usr/share/software-center/softwarecenter/enums.py and ...
10
votes
2answers
2k views

Symbolic links: why are they so bad?

Why is using symbolic links to change the default python version on Ubuntu considered as being unsafe ? I read this information on several forums but did not find an answer as to why is this so.
10
votes
2answers
8k views

Error installing scrapy in virtualenv using pip

pip install scrapy Downloading/unpacking scrapy Downloading Scrapy-0.24.2-py2-none-any.whl (502kB): 502kB downloaded Downloading/unpacking pyOpenSSL (from scrapy) Downloading pyOpenSSL-0.14.tar.gz ...
10
votes
1answer
9k views

How do I use Python with apache2?

I'm trying to get Python working with Apache, however I'm failing to have success with either CGI or mod_python. Does anyone know a good tutorial or something? Thanks.
10
votes
2answers
8k views

Ubuntu 14.04 LTS and Python 3.4.2

Is it possible update default Python 3.4 to 3.4.2? How?
10
votes
2answers
764 views

How do I make a rich menu for an appindicator?

I'm adding menu items to an appindicator in pygtk. I don't want them to behave like ordinary menu items: I want them to have normal appearance, but not to respond to mouse hovers and mouse clicks. The ...
10
votes
1answer
1k views

How to create a new Quickly application template?

Cannot find the answer elsewhere, I'm asking for a documentation of the process to create a new template for quickly. I'm interested in writing a pyside (python + qt4) template like the pygtk one. ...
10
votes
2answers
918 views

Is PyGTK still relevant?

I'm new to Linux but not to app development. I come from a RealBasic on a Mac background. I've accepted that I need to learn a new language to develop for Linux (since RB won't run on 64 bit distros ...
10
votes
1answer
728 views

How do I make the launcher progress bar work with my application?

Background Research I am attempting to update the progress bar within the Unity launcher for a simple python/Gtk application created using Quickly called test; however, following the instructions in ...
10
votes
2answers
3k views

I have installed python-doc. How can I access it?

Sorry if this is a such an obvious question, but where does Ubuntu put documentation packages for python, node.js, redis, mysql, mongodb, and other applications? And why I cannot access it by typing ...
10
votes
3answers
7k views

How to install and configure IPython so it uses Python3.2 on 11.10?

How to install and configure IPython so it uses Python3.2 on 11.10? I've checked that installing by sudo apt-get install ipython will uses python2.7. [EDIT1] $ sudo python3 configure.py ...
10
votes
2answers
276 views

How do I use get_media_file() in the latest Quickly?

I am writing a project with Quickly and GTK 3 and I want to use the get_media_file() helper so I can load an icon in my data/media directory. I can't see how I use get_media_file() with the latest ...
10
votes
4answers
433 views

How do I add a daemon to my Quickly application?

I am building a app with quickly, and I wanted to add a daemon that will run in the background. How do you do this?
10
votes
2answers
567 views

Quickly application with ListStore as preference

I'm starting to write a program with 'quickly'. A list of desired languages will be one prefereces. Example: languages = ["en", "de"] The (automaticly created) quickly code that handles the ...
10
votes
1answer
3k views

Is it possible to call Python functions from Libre Office Calc?

Consider the following simple Python function: def mysum(a, b): return a + b I would like to put =mysum(5, 7) in a cell of the Calc spreadsheet, so that is simply returns the number 12. Is this ...
9
votes
2answers
15k views

How can I remove python 2.7 after installing python 3.3?

I have successfully installed python 3.3 on Ubuntu 12.10. Since I don’t need multiple versions of python, I want to remove the existing python 2.7. When I try to do that, using sudo apt-get remove ...
9
votes
4answers
38k views

What is the best way to install python packages?

What is the best way to install python packages in Ubuntu 11? I am a recent convert to Ubuntu and want to learn best practices. For context, I am looking to install the tweeststream package, but I ...
9
votes
3answers
4k views

How can I change the wallpaper using a Python script?

I want to change my wallpaper in Ubuntu 11.10 (with Unity) in a small Python script. I found the possibility to change it via the gconf-editor in /desktop/gnome/background/picture_filename. With ...
9
votes
3answers
2k views

Where to store user settings for an app?

If I want my application to store a few settings, that persist when an application closes, then where should I store them? I'm not talking anything complicated: two booleans and a string (although in ...
9
votes
3answers
27k views

Problem installing Python-Dev

I am having trouble installing python-dev. It all started when I tried to install another Python package and got the error: SystemError: Cannot compile 'Python.h'. Perhaps you need to install ...
9
votes
2answers
2k views

Installing Pylint for Python3 on Ubuntu

My understanding is that the latest release of Pylint (1.0.0 at the time of this writing) has support for Python 3, but I can't get it to work on 64-bit Ubuntu 13.04 with Python 3.3. I followed the ...
9
votes
1answer
594 views

How to highlight buttons in a GTK toolbar

I've written an application using Python and Glade. The app has got a toolbar with a dark background, and each toolbar button has got a custom image (i.e. no stock icons are used). I've noticed that ...
9
votes
3answers
2k views

Has anyone managed to configure Nautilus to show EXIF data?

I followed instructions on the Ubuntu Forums to configure Nautilus to display additional information about image files - specifically, the EXIF data: [SOLVED] Adding mp3 info columns (e.g. bitrate, ...
8
votes
2answers
6k views

Why can't I import “pygtk” with Python 3.2 from PyDev?

I have installed Eclipse + PyDev + Python 3.2. Now I have two Python interpreters in PyDev: Python 2.7 and Python 3.2. If I try to execute command import pygtk with 2.7 interpreter it works fine, but ...
8
votes
4answers
12k views

Unable to download videos using youtube-dl ('sig error'), how to correct?

I used to download videos using youtube-dl command line tool, from the past two days whenever i try to download any video I get an error as shown below. $ youtube-dl ...
8
votes
2answers
6k views

Install uwsgi 1.2.5 via pip

Welcome, Currently I'm trying to install latest uwsgi on my VPS (Ubuntu 11.10) based on instruction from the site http://projects.unbit.it/uwsgi/wiki/Quickstart pip install uwsgi During ...
8
votes
1answer
12k views

Upgrading to python 2.7.5 on Ubuntu 12.04

Ubuntu 12.04 comes with python v 2.7.3 by default. I want to upgrade it to v 2.7.5. I tried the instructions given in this question, sudo apt-get install build-essential sudo apt-get install ...
8
votes
1answer
345 views

Create a quickly app with build dependencies

I am creating a Quickly app in Ubuntu that depends on Python Twisted, which is available in the package python-twisted. How should I add python twisted as a dependency so that it will be installed ...
8
votes
2answers
611 views

Can I use a desktop install as a server?

I'm new to Linux and Ubuntu is my first distribution. I have chosen Ubuntu because I want to learn more about Linux. I'm under time constraints and need to setup a server as soon as possible. I have ...
8
votes
6answers
1k views

Deleted the python binary, and can't recover using apt-get, what can I do?

Well. Yep. Wanted a fresh start because I was having dependency confusions, so I ran "whereis python" and literally erased all of the files and directories that came up. Then when I go to run apt-get ...
8
votes
1answer
2k views

How can I install a Gsettings Schema without root privileges?

The typical workflow to install a Gsettings Schema is this: Create a schema, with the extension .gschema.xml, with contents like this: <?xml version="1.0" encoding="UTF-8"?> ...
8
votes
1answer
1k views

What is python3mu?

I'm setting up PyDev for Eclipse, and I have to choose a version of Python for the interpretor. I want to use Python3, and I've been using python3 as my interpretor, so I thought /usr/bin/python3 ...
8
votes
2answers
4k views

How do I run a script when a Bluetooth device connects?

I'd like to start my music player (Clementine) when my bluetooth headset connects to my computer. How do I detect the bluetooth device connecting so I can run a script to start the player?
8
votes
2answers
6k views

How can I get pygame for Python3?

There is a package (python-pygame) for Python2 available from the universe repository. However, I want to work through the tutorial in the Invent with Python book. Going through SPM (Synaptic), I ...