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

72
votes
8answers
29k views

Is there an GUI Designer for python?

Is there a GUI IDE for programming python just like java has netbeans? I wanted one where we could drag & drop test boxes & labels just as we do in swing components using netbeans or eclipse. ...
49
votes
8answers
52k views

How can I install Python 2.6 on 12.04?

According to https://wiki.ubuntu.com/PrecisePangolin/ReleaseNotes/UbuntuDesktop "Python 2.6 is no longer available for install". I need to support legacy software that runs only on Python 2.6. How ...
45
votes
5answers
122k views

How do I install python 2.7.2 on Ubuntu?

I want to install python 2.7.2.tgz on Ubuntu, downloaded from http://python.org/download/. Is this a correct way to install : ./configure make make install If not , how can I do that?
45
votes
3answers
2k views

Is #!/bin/sh read by the interpreter?

In bash or sh, I guess anything which starts with # is a comment. But in bash scripts we write: #!/bin/bash And in Python scripts, there is: #!/bin/python Does this mean that # by itself is a ...
36
votes
5answers
6k views

How do I create a deb package for a single python script?

I have a single python script that I want to distribute as a deb package. It is a indicator which shows local date in Unity panel. I did follow create a .deb Package from scripts or binaries but I ...
31
votes
1answer
17k views

Should I use PyQt or PySide for a new Qt project?

Recently I've been involved in conversations about creating a Quickly template for a Qt and QtQuick Ubuntu app. The idea is to make it as easy to develop Qt apps from concept to package as it is right ...
28
votes
2answers
5k views

Connect WebKit WebView form to a Python callback?

I am writing a small Python and WebKit app; I am using WebKit as the UI for my app. What I want to do is to create an interactive element in WebKit (namely a combo box or a set of clickable regions) ...
23
votes
4answers
7k views

What are the packages/libraries I should install before compiling Python from source?

Once in a while I need to install a new Ubuntu (I used it both for desktop and servers) and I always forget a couple of libraries I should have installed before compiling, meaning I have to recompile, ...
23
votes
2answers
10k views

What's the best way to get Python 2.5 and 2.7 on Ubuntu 10.04

Ubuntu 10.04 has only two supported Python versions 2.6 and 3.1. Developers often need more, to test that their Python code works on 2.7, 2.5 (and maybe even 2.4 and older ones). What's the best way ...
22
votes
5answers
15k views

Will python2.7 be available for 10.04 in the future?

Since Ubuntu 10.04 is an LTS release will it support python 2.7 as a default package maintainer version or at least have a python2.7 package in future? Since it will be the last major python 2.x ...
22
votes
5answers
4k views

Setting up python to start learning

So I am interested in learning to code in python. I started with html and css which requires no set up just using gedit to write my code and testing on chromium. I was recently told to learn to do ...
21
votes
5answers
961 views

How to easily start a webserver in any folder?

I'm looking for a relatively painless way to launch a web server with document root in any folder I specify (or better yet, where I'm launching). I often try out new things like JS frameworks or so ...
21
votes
4answers
6k views

What's the difference between GTK and QT?

Please bear with me as I'm a newcomer to Linux. I've been writing GUI programs in REALbasic on a Mac for several years. I'm trying to learn Python and I want to write GUI apps for Linux (primarily ...
20
votes
2answers
2k views

What is the black header widget in some programs?

In some of the ubuntu programs (ubuntu control panel, system settings), but not e.g. in banshee, the top part of the window contains elements in dark tone (with the Ambience theme). But I cant find a ...
20
votes
4answers
4k views

Can I develop ubuntu for phones apps in Python? [duplicate]

Does anyone know if we can develop apps for ubuntu for phones in Python ? PyQT / PySide would seem to support also QML. But can we use them on the phones ?
20
votes
3answers
2k views

How to add support for the global menu to a python non-gtk, non-qt app?

I'm looking for good documentation (an example, tutorial, or guide) on how to add global menu support to a non-gtk, non-qt application. (In gtk it works 'magically' for the main menu...). The ...
18
votes
3answers
3k views

How do I get started creating an Ubuntu Desktop App?

I want to create an Ubuntu desktop app, specifically to replace Gwibber. I can code in Java, Python and a few other technologies. Adobe Flex would have been an option until Adobe decided to suck some ...
18
votes
3answers
3k views

How to find the number of packages needing update from the command line?

I'm working on some system admin automation using fabric and I'd like to be able to monitor the number of packages that need upgrading on a given machine. This is the same information that I can see ...
18
votes
1answer
21k views

Upgrading to python 3.2

I want to use new functools that provides with the lrucache, I am currently using python 2.6, which doesn't support this, What is the best way I can upgrade to python 3.2? or is there any other ...
17
votes
2answers
9k views

How to set up and use a virtual python environment in Ubuntu?

Python virtual environments are used to create isolated python environments to avoid dependency and version conflicts, and also indirectly takes care of permission issues. But what is the easiest way ...
16
votes
4answers
3k views

How to program a status icon that will display in Ubuntu as well as in other distributions?

The application in question does some action (here connecting audio to network streams) and runs minimized if these actions were successful. Therefore a status icon is needed to display the state of ...
16
votes
2answers
17k views

How do I run Python 3.2.3?

The description here says that 12.04 ships with python 3.2.3 as well. What command do I run to get this? Running python -v or python2 -V or python2.7 -V all give me the same result 2.7.3. There are no ...
16
votes
2answers
1k views

Developing Unity compliant apps in Python - where to start?

I'm an experienced programmer who is interested in developing apps for Linux, specifically GTK, and more specifically apps that are Unity compliant. Aside from the obvious step of learning Python, ...
15
votes
5answers
8k views

Python HTTPS requests (urllib2) to some sites fail on Ubuntu 12.04 without proxy

I have an little app I wrote in Python and it used to work... until yesterday, when it suddenly started giving me an error in a HTTPS connection. I don't remember if there was an update, but both ...
15
votes
1answer
11k views

Can I use easy_install?

Can I use easy_install on Ubuntu 10.10? If yes, then how?
15
votes
1answer
3k views

How do I send text messages to the notification bubbles?

I wrote a python code for getting random text into a .txt file. Now I want to send this random text into notification area via 'notify-send' command. How do we do that?
15
votes
3answers
3k views

Why does Ubuntu use Python 2.6 and not 3.X?

I have recently started learning Python and thus have learned that Ubuntu (10.10) uses Python 2.6. It seems to me that Python 3.X is still rather unpopular in the Linux/Ubuntu community. Why is that? ...
15
votes
2answers
7k views

easy_install/pip or apt-get

As noted in the Ubuntu wiki page on Rails it is recommended that gems manages your Rails/Ruby dependencies. What is the best practise with Python packages like Django? Should I install them through ...
15
votes
3answers
2k views

Is it possible to use Python with the Ubuntu SDK?

David Planella wrote in his answer to a question I posted that: ...the recommended way to develop apps for Ubuntu is the Ubuntu SDK. So I installed it, but looks like the supported programming ...
14
votes
6answers
2k views

Wanting to start development for Ubuntu (and most Linux distributions in general), which is suitable? Python or Vala?

I'm a computer science graduate, and learned languages like C, C++, C# and Java. Though I have more experience with Java. I want to develop for Linux and I'd prefer to develop for GNOME, I'm confused ...
14
votes
5answers
40k views

How do I install python imaging library (PIL)?

How do I install the python imaging library (PIL) on Ubuntu? I tried doing sudo apt-get install python-imaging but now when i run python selftest.py (a script I got from somewhere on the ...
14
votes
1answer
2k views

Dropbox Fails To Start With “VerificationError: importing pylinux…”

Dropbox Fails To Start With "VerificationError: importing pylinux..." . It seems that some recent Python update breaks Dropbox, resulting in the following error: Starting Dropbox...Traceback (most ...
14
votes
5answers
13k views

How to remove a deb without removing its dependencies

I would like to install the most recent version of boto, which I do via python setup.py install Yet when I try to remove the old version the following packages also get removed: apt-get remove ...
14
votes
5answers
5k views

How to run asynchronous tasks in Python GObject Introspection apps

I'm writing a Python + GObject app that needs to read a non-trivial amount of data from disk upon start. The data is read synchronously and it takes about 10 seconds to finish the read operation, ...
14
votes
1answer
3k views

Where is virtualenvwrapper.sh?

I don't know what's more embarrassing: that I don't know how to go about finding the answer to this question myself, or that it has to be asked at all in the first place, but... where does apt-get ...
14
votes
2answers
2k views

How can I write Nautilus scripts in Python?

I want to write a Nautilus script in Python. Is that possible? If it is possible, how can I do that?
13
votes
2answers
4k views

How to read dbus-monitor output?

i'm playing around with dbus-monitor to try and understand how dbus is working in Ubuntu environment. I have several questions in this regard: Could you please let me know how to read the following ...
13
votes
1answer
1k views

Is there a detailed API documentation on the python binding for appindicator?

I'm getting serous with a project of my own and need a good documentation on the appindicator module for python. What I've found so far: API documentation on dev.ubuntu.com Community wiki entry API ...
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
2answers
702 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
3answers
891 views

How do I call a dialog for authentication?

I am writing a gui program using wx module in python. In program whenever I am accessing a folder which requires root privilege then it asks password at terminal but I want to display the dialog to ...
12
votes
1answer
283 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
4answers
5k 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: ...
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
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
4answers
16k views

How to use Qt Creator with Python?

I want to use Qt for developing Ubuntu desktop, phone and tablet applications but I don't want to learn a new programming language (C++, JavaScript). Is it possible to write Qt application in Python ...
11
votes
1answer
6k 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
268 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
3answers
13k views

How to create a virtualenv with Python3.3 in Ubuntu?

I'm running Precise Pangolin amd64. I installed Python 3.3 from ppa:fkrull/deadsnakes. Now I want to actually use this new Python version in a virtualenv. But How can I do this? I get the following ...
10
votes
3answers
11k 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 ...