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

1
vote
0answers
68 views

installing Anaconda, errno 2 no such file or directory

I've taken a look at some of the other AskUbuntus, and none of them have fixed my problem. I've been running iPython for almost six months now in order to get some extra practice with the Codecademy ...
21
votes
3answers
2k views

Saving output of a grep into a file with colors

I need to save the result of a grep command into a file, but I also want the output file to be formatted and keep the colors just like in the terminal. Is there a way to do that? Maybe make grep save ...
2
votes
1answer
187 views

pip install virtualenv, error on ubuntu 15.04

How to fix this issue? and how to install pip and virtualenv on ubuntu 15.04 pip install virtualenv Traceback (most recent call last): File "/usr/bin/pip", line 9, in <module> ...
2
votes
2answers
54 views

converting BASH to Python (v2.6) [closed]

I have this code in bash and do not know how to translate the lines with 'ps -C.....' and ' ps -eo....' any help in how to write these lines? if [ "$SwapUsedActivity" == "true" ] then echo ...
0
votes
1answer
55 views

MAAS - Import PXE files - Not a gzipped file?

I'm currently trying to import boot images via the command line as via the gui just hangs When running the command 'maas-import-pxe-files' I get a IO error as shown below MAAS is running on a ...
0
votes
1answer
38 views

How do I install Python 3.2 on Ubuntu 14.04?

The default version that Ubuntu carries is Python 2.7 and Python 3.4. How do I get Python 3.2? There another question on this website where the topranked answer solves the issue for Ubuntu 13.04 with ...
2
votes
1answer
32 views

Persistence USB with External Python Libraries

I have a fresh install of a Ubuntu 14.04 on a flash drive with 4GB persistence space, and I want to install easy_install, pip, ipython, and other external python libraries that can easily be accessed ...
0
votes
1answer
414 views

How to exit from uwsgi server process

I'm trying to set up uWSGI for django using http://adambard.com/blog/start-to-finish-serving-mysql-backed-django-w/ and the tutorial at ...
0
votes
1answer
52 views

Upgrade from 12 to 14 failed with missing python package, now what?

do-release-upgrade aborted deep in the process. The main log file ends with the following. How do I recover this system? (The apt.log file seems boring). 2015-03-28 08:30:32,930 INFO Using config ...
4
votes
1answer
17k views

How to run a .pyc (compiled python) file?

When I compile a python file, I get a *.pyc file. When I try to run that, I get a message saying there is no program for running them. When I search for a program online via that option, it says there ...
0
votes
3answers
481 views

How can I install chainer-cuda-deps?

I am attempting to install chainer-cude-deps. When I try to install (sudo pip install chainer-cuda-deps), I get the following error: In file included from src/cpp/cuda.cpp:1:0: ...
1
vote
1answer
66 views

How do I get my “gedit” plugin to work?

I'm trying to install a plugin for the gedit text editor that will allow for split pane viewing of files; i.e. I will be able to view multiple files side-by-side (simultaneously). The plugin came in ...
0
votes
0answers
135 views

Pycharm cannot install packages because getting PermissionError: [Errno 13] Permission denied: '/home/m/.cache/pip/wheels/fe'

I want to install some python packages, but I am not able to do it because I am getting the following error: PermissionError: [Errno 13] Permission denied: '/home/m/.cache/pip/wheels/fe' I guess I ...
0
votes
2answers
169 views

Ubuntu 15.04 Linux 4.0 Python error while updating, Sub-process /usr/bin/dpkg returned an error code (1)

While running autoremove command or update or even for any install commands I'm getting following error. My System is Ubuntu 15.04 Upgraded from 14.04 and Linux kernel is 4.00 upgraded from 3.19. ...
0
votes
1answer
166 views

Having Problem with ipython notebook on ubuntu 14.04

I have installed ipython notebook in my system, but when I want to run it in terminal, the following error comes up: File ...
6
votes
2answers
5k views

How do I install Pygame in virtualenv?

In installed python-virtualenv, because this question said I should use virtualenv to install pygame. However, I'm not really sure how that's accomplished. What I did (following these instructions): ...
0
votes
1answer
12 views

Why the latest updates removes pycrypto-2.0.1

Why when I reinstall the latest unity-control-center it removes pycrypto-2.0.1 that I install manually and replace pycypto library with the latest one pycrypto-2.6.1?
0
votes
0answers
44 views

Executing Pure Data Patch from within Python/Shell on Raspberry Pi

I am searching for a way to execute a Pure Data patch from within a Python/Shell script. I have the PD patch (called sf.pd) on my Pi in a folder called /home/pi/pd. To execute the PD patch from the ...
1
vote
1answer
49 views

Can't pass file containing whitespace as command-line argument to SMS-sending Python script in Ubuntu Touch in Ubuntu Touch

I can send text messages by SMS using the command: $ /usr/share/ofono/scripts/send-sms /ril_0 07123456789 "iorem ipsum est" 0 Where /ril_0 is the SIM card/modem, 07123456789 is the telephone ...
1
vote
1answer
35 views

Help with an automatic email response system [closed]

I am planning to create a program(with python) that analyzes and responds to emails on ubuntu, but I cant seem to find anything that could serve as the receiving and sending part of the program(in ...
1
vote
5answers
218 views

Pass filename from bash to python

Lets say I have 1000 csv files that have random names in a folder test. and I have a python script script.py. I would like to write a bash script that would pass the name of each file in the folder to ...
1
vote
1answer
59 views

Executing python file from another script

I have a file called main.py and has the following code: from os import system from time import sleep from datetime import datetime while True: print(datetime.now(),"-+- Starting") ...
-4
votes
1answer
47 views

Opening folder in python [closed]

I want to open folder and read a .txt file from that folder. How should I write program in python for it? I have been trying os module but getting strange answer.
5
votes
1answer
175 views

How do I run a bash or python script via cron, visible on the local desktop

I have a production server that runs several bash scripts on the local desktop. Two scripts run all the time and don't need to be stopped. I have a third Python script that I need to start at 9AM. It ...
0
votes
3answers
42 views

Duplicate Python Installs

I was not aware that Ubuntu 14.04 already comes pre-installed with Python. However, I'm not sure if it's installed with Python 2 or 3. Either way, I went to the Python website, downloaded the package ...
0
votes
2answers
1k views

Python - AttributeError with hashlib: no such attribute: “openssl_md_meth_names”

I don't know why this is happening, but after some crazy recovery from installing python from source, when anything imports hashlib, it comes up with something like this error: Traceback (most recent ...
0
votes
1answer
157 views

Celery trying to connect to wrong broker

I have a Django project on an Ubuntu EC2 node, which I have been using to set up an asynchronous using Celery. I've been able to get a basic task working at the command line, using: ...
0
votes
1answer
36 views

Unable To Run Nightrain On Ubuntu 64bit 14.04LTS Please Help

$ ./nightrain Traceback (most recent call last): File "<string>", line 7, in <module> File "/home/naetech/Applications/Repositories/pyinstaller/PyInstaller/loader/pyi_importers.py", ...
1
vote
1answer
55 views

Python Install Questions - PyDoc Not Working - Questions on Using GitHub

This question is actually threefold. I have questions mostly regarding Python and the installation process. I also have questions on how I can find documentation for a module that is hosted on GitHub. ...
1
vote
0answers
17 views

how to install plugin for python v2.7

I tried to run a video DVD and it says you need to install plugin for python v2.7. I am using Ubuntu 13.04.I am very new with ubuntu. what codes shall i have to write to download the plugin and to ...
3
votes
2answers
145 views

Under the hood, what is Quickly made of?

under the hood, What is Quickly made of? It's a wrapper to python? It's a compiled language? It's portable? What about the architecture and the design?
0
votes
0answers
23 views

Accidentally uninstalled Python, now my Pc Lags in black screen [duplicate]

I am new to Linux. I am using this just for about a month, and when I wanted more space on disc, I typed to Terminal sudo apt-get remove Python. I did not know what the Python was, so i just ...
0
votes
1answer
78 views

Drop/Undo sudo privileges on .py file which runs inside a program which runs from sudo previleges

I need to run a program from sudo privileges and I am running .py file inside the program. So when my program runs from sudo then it automatically calls/runs the .py file with sudo. I am running file ...
1
vote
1answer
388 views

Unable to upgrade pip

Apologies for such a basic question... but am new to linux/ubuntu and haven't been able to find answer to this... Was trying to upgrade pip but ran into this... spelee@iggy:~/python$ sudo pip ...
1
vote
0answers
32 views

execute python package to download a pdf file

i am new in python. please dont bore. i have a python package to download pdf file from a specific site. i can not execute this package. Please help me someone to execute the package. thanks in ...
2
votes
0answers
218 views

Run an xinput command when a device is connected?

Due to a bug in the kernel driver for the Apple Magic Trackpad, two finger right click doesn't work by default. However, you can fix the issue by running the following: xinput set-prop $DEVICE_ID ...
0
votes
0answers
79 views

Python script stopped working: Cannot autolaunch D-Bus without X11 $DISPLAY jack server is not running or cannot be started

I have a Python script on a Raspberry Pi that streams radio. It was working great for a long time, but today not so much. Here is a reproducible example that produces the error message: import pygst ...
9
votes
3answers
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 ...
0
votes
1answer
27 views

How do you install an application that doesnt have makefile in folder?

Sometimes I download applications and they don't include a makefile; just a bunch of source code and an executable application. For instance, I downloaded tor but it comes with the application and a ...
2
votes
1answer
4k views

How do I install the 'python-uno' package?

I had a script, it is working with the package python-uno on Ubuntu 12.04 lts. The script is in python language and work with OOo to edit XLS files. Now I upgraded to 13.10 and it seems the uno not ...
1
vote
1answer
41 views

BASH->Python (2.6) piping

I need to translate this line of Bash into Python: sample1=($(/bin/cat /proc/meminfo | egrep 'MemTotal|MemFree|Cached|SwapTotal|SwapFree|AnonPages|Dirty|Writeback|PageTables|HugePages_' | awk ' { ...
1
vote
2answers
912 views

How to use Python like Windows? [duplicate]

For example , I write a Python program by vim , but how can I run it ? It just show a editor program when I double tap on it .
2
votes
1answer
117 views

Problems installing Numpy in Virtualenv

I have numpy installed globally (I think via Django) but I'm trying to install it within a virtualenv. When I run pip install numpy (within my virtualenv), it gets stuck at Running setup.py ...
1
vote
1answer
24 views

Establishing compute node problem faced off

I am going to establish a compute node on a Ubuntu virtual machine. following these steps as written down: configure a compute node I am stuck on apt-get install nova-compute-kvm python-guestfs I ...
0
votes
0answers
51 views

How to install python-dev - without using apt-get - on ubuntu 12?

The question is pretty descriptive as it's noted. I'm at a working environment that I have not much access over. I have wget and curl, but I can't find any resources.
3
votes
1answer
256 views

Alsa problems with python2.7- Unable to open slave

I am using python's module pyaudio to process sound but ALSA returns: ALSA lib pcm_dsnoop.c:618:(snd_pcm_dsnoop_open) unable to open slave ALSA lib pcm_dmix.c:1022:(snd_pcm_dmix_open) unable to open ...
1
vote
0answers
84 views

Where to obtain ipython kernspec for Python 2.7

I'd like to work with Python 2.7 using Jupyter, but it doesn't come up as an option when I click to create a new notebook. I read that I need to install the ipython 2.7 kernspec file, but I get this ...
1
vote
1answer
122 views

Message- Cannot find installed version of python-jgango or python3-django

I'm new to Ubuntu, and I love it so far. I have been trying to install Django for a website development project. In the terminal, when I start the python interpreter and type import django ...
1
vote
1answer
60 views

launch ipython but not like root

ipython is launched like root (UID); ok, but I need that after ipython cann't run and don't allow, script/code that can gain root privilegies. eg I launch ipython, ok the UID is root. And in my ...
1
vote
1answer
308 views

nvidia-settings ImportError: No module named 'dbus'

I try to switch my graphics card via NVIDIA X Server Settings. However when I click on NVIDIA: Traceback (most recent call last): File "/usr/share/screen-resolution-extra/nvidia-prime.py", ...