Tagged Questions

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

0
votes
1answer
291 views

How to add a back button to go back to previous page [duplicate]

I'm currently new to Ubuntu programming, and learning the basic's of it. I've been following this tutorial as some of you might know in previous questions asked about it I've made before. Now, I've ...
2
votes
0answers
94 views

Terminal won't print “Refresh” in terminal

I have a slight problem today with my Ubuntu app. I've been following a Youtube tutorial. I've provided the link below with the rest of the links provided to help you find out the cause of the ...
2
votes
1answer
376 views

How to install a Python module to the non-default Python

I need to install mysql.connector to python3 but as python 2.7 is the default, it'll go there. How can I specify what python I want the module to be installed into? (I'm using mysql.connector.deb ...
0
votes
2answers
2k views

I get a error “IndentationError: unindent does not match any outer indentation level”

I get this error: Traceback (most recent call last): File "bin/mybrowser", line 32, in <module> import mybrowser File "/home/shaunyo/mybrowser/mybrowser/__init__.py", line 14, in ...
1
vote
2answers
256 views

How to execute this specific python script (attached in the question)

I Have a small net and last 2 weeks i get a lot of disconnections on my wireless stations a friend of mine told me that 90% i get attacked by deauth packets i i researched a bit and found this py ...
0
votes
1answer
104 views

Is there an easy guide on how to prepare my python3 script for upload to my ppa?

I have a python3 script (4000 loc) written in PyQt4 with four, five dependencies. In the same folder where that script is placed there are some subfolders where all additional files (icons, saves, ...
0
votes
2answers
4k views

How can I run python scripts on my webserver?

I have a test script, /var/www/etym/cgi-bin/test.py #!/usr/bin/python # -*- coding: UTF-8 -*- # enable debugging import cgitb cgitb.enable() print "Content-Type: text/plain;charset=utf-8" print ...
0
votes
0answers
24 views

Python : Need help in installing it in ubuntu 12.04 [duplicate]

Initially i installed python3.3 from source but then i removed and deleted the directory /usr/lib/python3.3. When I am installing using aptitude I am getting this error: Unpacking python3.3 (from ...
2
votes
3answers
1k views

Problem in installing Python 3.3 in Ubuntu 12.04

Initially I installed Python 3.3 from source, but then I removed and deleted the directory /usr/lib/python3.3. When I am installing it using aptitude, I am getting this error. Unpacking python3.3 ...
3
votes
5answers
10k views

Open Python file with IDLE using Terminal on Ubuntu 12.04

How can I open python file (from desktop) with IDLE, using Terminal on Ubuntu 12.04? I have tried to do this way: $ idle open python_file.py Instead of open my file it's create two more files: ...
1
vote
1answer
1k views

apt-add-repository raises an error [closed]

I’m trying to install JDE (Java Development Environment), but apt-get fails with the following error: me@ubuntu:~/$ sudo add-apt-repository ppa:webupd8team/java You are about to add the following PPA ...
1
vote
2answers
923 views

What is the difference between IPython and IPython3?

They are both on the repos. But I can't find out what the difference is.
0
votes
1answer
435 views

Install Python 2.7 on Ubuntu 12.4

I have install Ubuntu several day ago. I have install Python on Windows before and everything was simple. Now on Ubuntu I’m getting stuck with installation of Python. So my question is: How can I ...
2
votes
3answers
5k views

Bash cut and grep commands through python

I've tried to read a txt file and find the lines which contain a certain word "checkout_revision". I want to find these lines one by one in a for loop and store them in my variable, let say temp. I ...
12
votes
2answers
7k views

How to use the newest ipython in ubuntu12.04?

How to use the newest ipython in ubuntu12.04? The newest ipython is 1.0. The ipython in official software center is too old. Thanks
3
votes
1answer
280 views

Quickly application create config folder and config file under user's home folder

I want to create an app with Quickly but i have a question: Lots of applications create config files under ~/.config or ~/.application/config in home folder of current user and keep configs, user ...
1
vote
1answer
47 views

Are Python apps allowed in Ubuntu App Showdown?

I want to know if python apps (containing only a .py file) are allowed in the latest app showdown. If not, how can it be ported to QML?
1
vote
2answers
76 views

Prevening svn checkout list to be shown in terminal

I wrote a python code and at some point it checks out using svn. I don't want to see the outputs of svn on my terminal screen. I heard that to block this, I should use /dev/bin or something like that, ...
1
vote
1answer
834 views

Can't install python-dev. Packages have unmet dependencies. I think it's a wrong Python version

root@Managementserver:~# sudo apt-get install python-pip python-dev build-essential -y Reading package lists... Done Building dependency tree Reading state information... Done build-essential ...
3
votes
1answer
378 views

Is it good practice to upgrade .deb packages with pip?

It seems some blogs recommend installing pip and setuptools(actually distribute on Ubuntu) with: $ sudo apt-get install python-pip python-setuptools And then upgrading them with: $ sudo ...
1
vote
2answers
454 views

After PIP install --upgrade Dpkg still lists old python packages

I recently upgraded all python data analysis tools using pip. When I do dpkg -l |grep python I see the old version numbers of the software I just upgraded via pip. How can I ensure that the dpkg ...
0
votes
1answer
1k views

IOError(13, 'Permission denied')

I'm running a python program and I cant save any changes and I get this error message... < Function saveFile at 0x31dfb90 >: IOError(13, 'Permission denied') If you need to know any other info ...
0
votes
1answer
129 views

preventing pip from removing system packages during upgrade

I have a fairly straightforward Ubuntu (13.04) desktop installation, which comes complete with several Ubuntu-packaged Python utilities -- these live in /usr/lib/python2.7 and are owned by root. I ...
1
vote
2answers
134 views

Python startup icon

Using Ubuntu 13.04. I have never coded or know how to. I can only click on a icon and hope it run. Now I want to learn Python 3. I extracted -- Python 3.3.2 xzipped source tarball (for Linux, Unix or ...
1
vote
1answer
216 views

Executing script from shell problem

Lubuntu Raring Ringtail. I want to be able to execute my scripts with ./ I start my python script with #!/usr/bin/python and it says bash : ./myscript.py: /usr/bin/python^M: bad interpreter: No such ...
2
votes
0answers
81 views

Failed to install “Calendar for LibreOffice” in 12.04 [closed]

If anyone know what these errors mean, please enlighten everyone, thanks!
7
votes
1answer
10k 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 ...
-3
votes
2answers
154 views

What documentation and help resources are available for setting and examining UFW rules? [closed]

The guy who wrote ufw is too smart for me. Is there any documentation for any of the python code? Some things I'm trying to do are: Allow/close ports by number Get the currently set rules Remove ...
0
votes
1answer
272 views

No module named 'kernmagic' in ipython

I'm running Ubuntu 13.04 and upon starting up ipython (0.13.2), I get this warning: ImportError: No module named kernmagic I've tried re-installing ipython and that didn't work. Does anyone have ...
1
vote
1answer
45 views

How to make a Quickly project standalone?

I have a Quickly project. But now I want it to be independent from Quickly. How can I do it? How can I run it without typing 'quickly run'?
1
vote
2answers
516 views

Using Python 3.3 on Kubuntu 13.04

I am starting with my first Python project and choose to go with version 3.3 of the language. I'm doing this on a Kubuntu 13.04 x64 box. I appear to have both 2.7 and 3.3 installed (at /usr/bin/python ...
1
vote
1answer
742 views

Set CLASSPATH for python

I want to execute a python file called "ex1.py". The execution works fine, the program does, what it ought to do. The problem is the following: This file is stored in the folder ...
3
votes
1answer
3k views

How to install PyV8 in Ubuntu 13.04?

I want to install PyV8 in Ubuntu 13.04. However pip install -v pyv8 takes super long to build and finally fails. How can I install PyV8 on a Ubuntu 13.04 machine? Here is the error log ...
1
vote
1answer
875 views

python troubles on ubuntu 12.04

after a system updates I having troubles with a python based Apps The Updater-manager doesn't download the updates packages, and I realized this python trobles because I use flexget for RSS ...
1
vote
1answer
2k views

Install Python in Wine

I need to install the Windows version Python 2.7.5 32Bit on my Ubuntu Box in Wine (because I test Euler Math Toolbox on Wine, and this cannot use the native Python). Whatever I do, I get the an error ...
1
vote
1answer
989 views

MAC OS X virtualization with KVM on the mac mini : seabios error

Since I'm a legal owner of the first generation of Mac Mini with a regular Snow Leopard license,I'm trying to follow this tutorial with the goal to virtualize Mac Os X with KVM on the second part of ...
0
votes
1answer
571 views

Check if torrent file is complete before copying

I have a crontab command that daily copies .iso files found within my torrents folder into an iso directory on a separate partition. My problem is that multiple .iso files will still be in the process ...
2
votes
1answer
214 views

Using unicode correctly in Python 2.7, Ubuntu 13.4?

In the latest Ubuntu, with the default Python (2.7.4), I can't get unicode to work. This is what's happening: >>> print('tři') tři >>> d = {3:'tři'} >>> d[3] 't\xc5\x99i' ...
1
vote
1answer
168 views

Glade, quickly and changing an image with code

I have created the default ubuntu-application template using quickly and I'm trying to work out how to change the displayed image through code. The default image shows an ubuntu logo with the path ...
0
votes
1answer
165 views

How to install Python 2.5.4 in Ubuntu 11.10? [duplicate]

I've been reading through some posts on how to install Python 2.5.4 in Ubuntu but I can not manage to find a solution to my problem. The version of Ubuntu I have is the 11.10 and the one of Python I ...
3
votes
0answers
94 views

Application should skip the unity launcher [duplicate]

How can I skip the unity launcher for a (Py)Qt-app? As you see when running the code below, there is an icon in the launcher. I don't need that icon because I manage the windows of that application ...
3
votes
1answer
123 views

UFW python documentation

I'm trying to access ufw with python, but on line 53 of backend.py, they raise a weird error that makes no sense: Traceback (most recent call last): File "mymodule.py", line 1467, in ...
4
votes
2answers
306 views

How can a Debian package install Python modules from PyPI

This question tries to complement this one . I have a python app which uses third party modules from PyPI. I want to package my app into a debian package, but don't know how to handle python ...
4
votes
2answers
22k views

Copying multiple specific files from one folder to another

I have a large folder of pictures (thousands), and I have a long list of files, by exact file name, that I need to copy to another folder. I want to know if there is a way I can select several ...
0
votes
1answer
673 views

Python on Ubuntu 13.04

How can I download and install Python on Ubuntu 13.04? I'm a newbie in Ubuntu. I've only been using Ubuntu for the last 3 days.
0
votes
2answers
693 views

Still cannot install scipy

I'm trying to install the python package scipy. When I type sudo apt-get install python-scipy here is exactly what I get mark@mark-N53SV:~$ sudo apt-get install python-scipy Reading package ...
0
votes
1answer
158 views

Is there a standard installation location for scripts?

I'm deploying a bunch of python scripts to my build, test and soon production server. It can be nodejs or any other thing I want to run under nginx so the location should be generic rather than ...
1
vote
0answers
21 views

Don't show a running application in the launcher (PyQt4) [duplicate]

I write an application that has an icon in the upper right corner in the notification area, so there is no need to put its icon in the launcher. But it is automatically put there. How do I disable ...
0
votes
2answers
198 views

How to get wmctrl output in python

How can I get the output of the terminal code "wmctrl -m" $ wmctrl -m Name: GNOME Shell Class: N/A PID: N/A Window manager's "showing the desktop" mode: ON in python code? I don't know how to ...
2
votes
1answer
143 views

Ubuntu Python Error

It's been months since I used my ubuntu pc. I updated and upgraded it yesterday but when I run help('modules')in python I encounter this I haven't tried using python before I updated my system so ...