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

5
votes
2answers
191 views

How do I package a python app for ppa?

I am planning to package FBuntu into PPA for easier distribution. The nature of this app is that the user has to make specific edits to the auth.py file to make it work and hence I am stuck from ...
53
votes
1answer
36k 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 ...
8
votes
1answer
705 views

How to make Glade load translations from /opt

I've created an application that I'd like to submit through the Ubuntu app developer process. One of the requirements for the process is that when installed, all files go into the ...
3
votes
2answers
1k views

Problems with simple media player tutorial [duplicate]

Possible Duplicate: Facing problem with “gtk.RESPONSE_OK” in the simple-player quickly tutorial I'm following along with this tutorial, but came to a stopping point where the program has an ...
5
votes
1answer
1k views

How to make a Gtk.ComboBoxText's entry editable in Glade

I'm using Glade to write a PyGI app, and I've come across a problem whereby I've got a Gtk.ComboBoxText with a Gtk.Entry, but I cannot make the entry editable for some reason. I.e. when the UI is ...
3
votes
2answers
351 views

How to programmatically fetch a list of applications from the Software Center

Im writing a PyGI app where I'd like to show a list of matching applications from the Ubuntu Software Centre in an auto-completion text entry or dropdwon. I haven't yet figured out the best way to ...
1
vote
1answer
5k views

Path to user desktop using python

This may seem stupid to a few, but I was wondering if there was some code to find out the operating system of the present user, and then the path to his Desktop using python.
4
votes
1answer
93 views

How to dynamically get name, version and other info from a Python app at runtime

I'm writing an Python app that makes use of a Gtk.AboutDialog. Some of the information shown in the dialog comes from setting properties for bits of info I've just given elsewhere, and I'd like to ...
11
votes
3answers
7k 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?
2
votes
2answers
506 views

Why can't I log in after unistalling Python 2.7 and installing Python 3?

I uninstalled the Python 2.7 package to try and upgrade to Python 3. I uninstalled Python 2.7, and noticed some of my launcher items were completely gone. At this point I had installed Python 3. Now ...
3
votes
1answer
289 views

Where is the pygame template in Quickly?

Same as the title says. When I want to create a new Quickly project, I don't get the pygame template option any longer. ubuntu-application ubuntu-cli ubuntu-flash-game Those 3 are the templates ...
9
votes
1answer
802 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 ...
4
votes
1answer
2k views

How to change the cursor to hourglass in a python gtk3 application

I've a function taking quite a long time to perform and I'm trying to change the cursor to an hour glass during the time the function is executed. But it only works the very first time the function is ...
6
votes
1answer
4k views

How to install keryx?

How to install keryx in ubuntu 12.04? knowing that keryx1.0 needs python <2.7 and ubuntu 12.04 has python2.7.3 so what could i do either to downgrade python or installing keryx bas some way. Also ...
2
votes
1answer
1k views

How to get the user downloads folder location with Python

So, I'm developing a simple download manager powered by Wget, [EasyDownloader][1], which I'm using for learning Python, and I have a problem. I want to save files at the Downloads folder, but it's ...
3
votes
2answers
879 views

Taking timely screenshots of particular sites

I have a website where I have to take weekly screen shots of sister sites. I was wondering how this maybe done. I had obtained the code for taking screen shots but have no idea how to open up the ...
1
vote
1answer
939 views

gtk3 window is not redrawn correctly

I am creating a simple GTK3 application. The main toplevel window has a search button which will display another toplevel gtk3 window. When I click the close button (near the titlebar) on the second ...
3
votes
1answer
1k views

How to get a proxy for DBus object that is not well known?

I'm endeavouring to use dbus to react to a particular signal (user clicks on an appindicator menu on the unity top panel). From using dbus-monitor, I've found the relevant signal that I'd like to ...
7
votes
1answer
684 views

How to embed a GtkAboutDialog's content in a GtkNotebook widget

I'm writing a Python app that is tab-based, and I don't want it to have any additional pop-up dialogs. I'd like to use the Gtk.AboutDialog functionality, but I don't want it to appear as a separate ...
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. ...
1
vote
1answer
233 views

python-pandas install wants to remove R

Ubuntu 12.04 LTS When trying to install python-pandas 0.7.0-1, Synaptic wants to uninstall my complete R installation. This does not make any sense. Is it a bug or a feature?
7
votes
2answers
2k views

How to add checkbox or radio buttons to a Unity quicklist?

I have been searching how to make that happen but i can't find it anywhere. I even guessed how to enable/disable the quicklist item, so as how to add function invoked after the item is clicked, but ...
19
votes
2answers
24k views

How do I run Python 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 ...
3
votes
1answer
466 views

Python gzip fails on Ubuntu 11.04

This function is based on the Python sample code @ http://docs.python.org/library/gzip.html. It runs reliably on Ubuntu 10.04 with its default Python 2.6x. On Ubuntu 11.04, however, the code fails @ ...
0
votes
1answer
344 views

Installing the Numenta Platform

I want to install the Numenta Platform in Ubuntu12.4. It created by python 2.5 and for Ubuntu 9.4. You can see the installing step and requerment in the below link The Numenta installing help But ...
4
votes
2answers
1k views

KEY.is_pressed() in gi.repository.Gdk?

I was wondering if anyone knew how to detect if a key is currently pressed with either Gtk or Gdk and python? I don't want to use the key-pressed or key-released event for this scenario, but rather ...
0
votes
1answer
679 views

WxPython 2.8 Offline Installation on Ubuntu 9.10 with 2 version of Python

How do you do an offline installation of wx 2.8.12 for python2.7 on Ubuntu with python 2.6 as default Python? Tried searching on google but can't found anything specific. I'm a noob with Linux. ...
1
vote
1answer
897 views

How can I install Python 2.7 x64 in x64 wine on 12.04?

It keeps failing when I run wine msiexec /i python-2.7.2.amd64.msi /qn as recommended as a workaround for an installer bug in some google results. I just wanted to help the next guy that encounters ...
4
votes
1answer
1k views

PulseAudio and Python3

Accessing PulseAudio with Python2 is a bit tricky, but it works with the help of ctypes. The problem is that the same code fails to work with Python3. Apparently something was changed in ctypes, but I ...
4
votes
1answer
2k views

Where is libpython-dev?

I've just upgraded to 12.04 and I can't find libpython-dev anymore. Can you tell me where it is?
1
vote
1answer
404 views

How to include locally build Python package system-wide?

For example: I build numpy with Intel MKL libraries and it's available in Python shell, but if I want to install some package from repository that depends on numpy, my build is not considered. What ...
3
votes
2answers
700 views

How can I get the source code to gnome-system-monitor and use it in my application?

I want to create a system monitor quite similar to gnome-system-monitor in ubuntu using python. I have used quickly application for the GUI and now i want to show the cpu history as shown by the ...
1
vote
2answers
1k views

Python, Gtk3 and Gstreamer

This isn't a really happy combination, but it does work for the most of the time. However, I just bumped into a problem with Gio.File. This will always result in TypeError and Python segfaulting: ...
71
votes
8answers
80k 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 ...
13
votes
3answers
3k 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 ...
3
votes
1answer
226 views

Unity lens not included in global search

I'm using the quickly unity lens template here http://developer.ubuntu.com/2012/04/how-to-create-a-wikipedia-unity-lens-for-ubuntu/ It works quite all right, but even though i have set ...
1
vote
1answer
1k views

How to get pygtk with python2.6 ? the update to 12.04 removes it. (cannot go python2.7 because of specific extensions)

I have updated to the latest 12.04 and it removes the pygtk bindings for python2.6. I've looked at the python-gtk package and it now installs only the lib for python2.7. The problem is : I have an ...
3
votes
2answers
947 views

How to let an icon in the launcher wiggle?

Trying to let my python application inform the user by wiggling or shaking its icon in the launcher, I found: Wiggling seems to be the "urgent animation": How can I change the wiggle time of ...
2
votes
1answer
2k views

Installing matplotlib 1.1.0 on Ubuntu 11.10

I installed matplotlib 1.1 from source, but I cant get any plot to show. python setup.py build shows the following: BUILDING MATPLOTLIB matplotlib: 1.1.0 python: 2.7.2+ ...
3
votes
1answer
2k views

“Additional data from the script executed” message in Inkscape

This is very irritating. I'm Using Ubuntu Oneiric and when I use Inkscape and make a couple of copy-paste operations inside the image, I get the following popup message: Inkscape has received ...
3
votes
2answers
137 views

How to add Quicklists to GTK2 application?

We want to add Quicklists to our app Nitro. However Nitro uses GTK2 as it uses the pywebkitgtk library. As far as I'm aware, we can't use Quicklists because it requires PyGI which requires GTK3 and ...
8
votes
1answer
257 views

Only show a menu under Unity

We want our app Nitro to be more native on Ubuntu. We're going to do this by adding Unity quicklist support & appmenu support. Is it possible for the app to only utilize the app menu? If the user ...
2
votes
1answer
212 views

how to fix ipython notebook 0.12 dashboard links

I've installed ipython 0.12 on a freshly installed machine with ubuntu 12.04 (precise), mainly because I wanted to use the notebook interface. Now it turns out that all the links in the python ...
2
votes
0answers
913 views

how to upgrade to latest python? [duplicate]

Possible Duplicate: How to update ubuntu’s python with latest version from source? I am using ubuntu 11.04. by default, there's a python already installed, it is version 2.7.1+ I know the ...
4
votes
1answer
959 views

Working with quickly, are there any gtk.Builder code sketching tools that integrate?

Example: quickly create ubuntu-application testing quickly design #makes changes #insert some other command here that would be roughly equivalent to 'quickly sketch' quickly edit #to populate the ...
4
votes
1answer
2k views

Executing “unicode” Python script from Gedit vs Terminal

As can be seen from screenshot, same script run from Terminal and Gedit behaves differently - in terminal script executes succesfully and in Gedit it raises error: But if I change python in Gedit ...
1
vote
1answer
131 views

Fix Nautilus URIs in a Python script

I have a very basic Python script I wrote mostly for learning purposes. It opens a terminal in the current folder. However, I can't get it to work in folders with accented characters in the URI ...
1
vote
2answers
1k views

Build binary deb package from python source

I have created python package (using Ubuntu Quickly) and want to create deb package. Unfortunatelly Quickly builds package with source python files (.py) and I want not to include source files. The ...
0
votes
4answers
3k views

Help with installing Gnome Shell Google Calendar Extension

I am having trouble running the script to install the gnome-shell-google-calendar extension into Gnome Shell. I keep getting this: rafael@Raf:~$ ./calendar/gnome-shell-google-calendar.py Logging in ...
22
votes
7answers
40k 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 ...