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
1answer
75 views

How to add a python script as a terminal command? [duplicate]

Lets say I have a script which creates a file and writes something into it (but could be anything). It could be a script that runs a set of xrandr commands to set a resolution, for example. Is there ...
2
votes
0answers
24 views

Does Python AppIndicator3 on KDE support labels?

I've just moved from Ubuntu to Kubuntu and I have a small script written in Python that used to display a brief status indicator message (how long a service on our network has been up) on my screen ...
0
votes
1answer
72 views

`zip` works in shell but not in Python script

According to this post I'm calling the zip command using os.system() in Python. At the command line it works: zip -r /Backups/backups/20152011-120209{.zip,} When I call this from a Python script ...
18
votes
4answers
69k 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 ...
17
votes
2answers
8k 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 ...
4
votes
1answer
5k views

pyvenv vs venv vs python-virtualenv vs virtualenv and python 3

malikarumi@Tetouan2:~$ pip install virtualenv Collecting virtualenv Downloading virtualenv-12.0.7-py2.py3-none-any.whl (1.8MB) 100% |################################| 1.8MB 330kB/s ...
0
votes
0answers
76 views

sudo can't find module rospy

I am using ROS (robotic operating system) on a raspberry pi running ubuntu and trying to setup a simple talker/listener. My problem is that then I need to run my script as root to access the GPIO ...
3
votes
3answers
59 views

Using different version of Python

I am using a server that I do not have admin access on. There are several versions of pythons installed. Say one is in /some/home/directory/Python2.6/ and the other in /some/home/directory/Python2.7/. ...
1
vote
1answer
83 views

Subliminal does not work in Ubuntu 15.04/15.10

File "/usr/bin/subliminal", line 5, in <module> from pkg_resources import load_entry_point File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 3020, in <module> ...
3
votes
1answer
3k views

Platform not supported for Tensorflow on Ubuntu 14.04.2

Tensorflow is a numerical computation software http://tensorflow.org/get_started/os_setup.md#binary_installation The installation instruction says to simply pip install on Ubuntu but I'm getting the ...
0
votes
1answer
948 views

Torbrowser-launcher does not start because of 404 error when trying to update itself

I use torbrowser-launcher (package version 0.2.0-2 from the Wily/universe amd64 repository on 15.10) which runs Tor Browser 5.0.4. Since today, after the update to 5.5a4-hardened became available, ...
5
votes
3answers
146 views

Running a command at startup not working (due to network not being up when the code was run)

I want to run a python script automatically when ubuntu starts up. Normally what I have to do is open up the command line on ubuntu and type python /home/ubuntu/Desktop/UDP_Server.py This will run ...
0
votes
0answers
25 views

How to package and ship a command line app in ubuntu? [duplicate]

Suppose I have a simple python program that prints 'Hello! World'. Now how can I turn it into a Command line utility like ls. A utility which I can install using apt-get install the_name. Next ...
0
votes
2answers
41 views

Difference between “pip install sompackage and python pip install somepackage” commands

I had to install Sphinx on Ubuntu for use with python (django) and I came across this two commands: pip install Sphinx, and then I saw this too python -m pip install Sphinx. Are there any difference ...
0
votes
1answer
50 views

How to change theme of python idle

Add the lines below to : Ubuntu(~/.idlerc/config-highlight.cfg) what is that mean? i can't find that location, can anyone explain reallllly detaily?
0
votes
3answers
5k views

fatal error :“python.h” no file or directory?

while looking for the solution of hungarian problem,I found this github link I went through the readme.md file and I performed everything described there, After copying hungarian.so in my directory ...
0
votes
0answers
30 views

install additional modules pyotherside

Recently I startred developing an ubuntu sdk application with QML and Python. For the python interpreter I use pyotherside but I need to import the yowsup library. Is it possible to do? Thanks in ...
1
vote
1answer
43 views

Ubuntu: Update Scipy-stack for Python 2.7

I'm very fresh on linux, so there might be some obvious misssteps in what follows. I've freshly installed the last Ubuntu LTS version yesterday, and also pyCharm (Python editor). I went on updating ...
16
votes
3answers
17k views

Ubuntu 14.04 LTS and Python 3.4.2

Is it possible update default Python 3.4 to 3.4.2? How?
0
votes
2answers
124 views

I cannot install python-numpy [duplicate]

I have Ubuntu 14.04 and I cannot install numpy. here is my attempt: ohad@ohad-Vostro-3300:~$ sudo apt-get install python-numpy [sudo] password for ohad: Reading package lists... Done Building ...
1
vote
1answer
131 views

Validate and format JSON without alphabetically sorting the data with 'jsonlint'

The package python-demjson provides the jsonlint command. I use it like this to format my JSON data: jsonlint -f input.json > output.json But the data is not in the original order any more, ...
4
votes
2answers
12k views

How to play a fixed frequency sound using Python

I have tried a number of ways of playing a fixed frequency sound (e.g. 1000Hz) and nothing works. I have downloaded "beep" and that makes no noise. I tried interfacing to pyao, and that had no ...
19
votes
6answers
28k 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 ...
1
vote
0answers
182 views

Textstat not running functions

I just found the link on how to install textstat on my python idle and I was successful in getting it to work. However, when I import textstat everything seems fine until I try to run a function. It ...
0
votes
4answers
3k views

“Cannot compile 'Python.h'. Perhaps you need to install python-dev|python-devel” while installing PyPy version of Numpy

I am trying to install the PyPy distribution of Numpy (Note that PyPy requires a different version of Numpy than that found in the repositories), but get the error: Cannot compile 'Python.h'. Perhaps ...
7
votes
3answers
5k views

python-nltk on Ubuntu 12.04 LTS: nltk.download('brown') results in HTML error 401

I have installed python-nltk on Ubuntu Server 12.04 using apt-get. But when I try to download a corpus, I get the following error: $ python Python 2.7.3 (default, Feb 27 2014, 19:58:35) [GCC 4.6.3] ...
0
votes
1answer
156 views

I've broken command not found?

I was messing around with bower, npm, and node, as I was trying to upgrade ember-cli, and I broke something strange. I get the following python error whenever I type a command that is not found in ...
0
votes
0answers
63 views

Creating a basic service in Ubuntu server

I am new to Linux/Ubuntu and Python so forgive me for asking basic question. I have written a basic Python script which keeps an eye on bytes received using psutil's function and spits out a print ...
27
votes
6answers
73k 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 ...
1
vote
2answers
2k views

Python 2.7 matplotlib provides error?

import numpy as np import matplotlib.pyplot as plt provides the error Traceback (most recent call last): File "/home/xx/PycharmProjects/Udemy/Array_Processing.py", line 2, in <module> ...
1
vote
1answer
76 views

Exceptions/OS Errors installing graphlab

I've been trying to install graphlab on my machine, and keep running into errors. I used the following command: pip install graphlab-create and it then runs through most of the install, but then ...
0
votes
1answer
132 views

Ubuntu 14.04 Depends: python (< 2.8) but 3.5.0-1 is installed

I have tried to install python3.5 following this instructions. $ auto-apt run ./configure $ make # checkinstall Actually python3.5 works well. But during installation previous version was replaced. ...
-1
votes
1answer
972 views

I am running Ubuntu 14.04, python 2.7.8, I try to install python-setuptools, but it is giving following message

I am try to install python-setuptools but getting following messages: You might want to run 'apt-get -f install' to correct these: The following packages have unmet dependencies: $ sudo apt-get ...
2
votes
3answers
199 views

How can I divide an output with 2 delimiters?

By dividing with the "·" and " " characters, I would like to turn this: Hel·lo my name is E·ric To this: Hel·lo my name is E·ric Hel·lo my name is E· Hel·lo my name is Hel·lo my name Hel·lo my ...
1
vote
1answer
142 views

Can't run Anaconda installer on Linux terminal

I downloaded Anaconda2 (for Python 2.7) from the website and when I try to run the installer the running stops when I press Enter to accept the license conditions. Does anyone have any idea why it ...
5
votes
1answer
106 views

How to sort audio files according to their cut-off frequency (real bitrate) in kHz?

I have some music collection and I want to sort/filter them easily according to their cut-off frequency (real bitrate, usually in kHz. I used to use Spek for showing me this information, but Spek ...
2
votes
1answer
37 views

Make Espeak read the words from picture on ubuntu [closed]

I m working on a project that helps visually impaired people to listen to the writings on the printed paper. I have dealed with the part of converting printed text picture into pdf file with digital ...
0
votes
3answers
141 views

How do i get the Python Interpreter

I have Lubuntu. Like version 14.04 i think. Its supported till 2019 i do know that. I have python installed i think. I type "python3" into the terminal and it just allows me to code in the terminal. I ...
1
vote
1answer
145 views

Python error “version OPENSSL_1.0.0 not defined in file libcrypto.so.1.0.0…” when trying to run command in PHP scrip (LAMPP)

When in Ubuntu 14.04: I run a command of script written in Python with shell it normally runs. I try to run same command using PHP (lampp) I get this error: [errors] => Traceback (most recent ...
1
vote
1answer
34 views

Python os.getlogin() vs BASH : who

I have formed 3 sessions with user accounts and I got no problem with Unix: who command but why I am unable to get correct response with python : getoslogin() function. Please find attached image for ...
6
votes
1answer
19k views

Unable to locate package python-pip

Hi I am trying to install electrum in my ubuntu live usb. Please forgive me because I am very new to this OS. I have also made a presistence 4GB space for future installation sofwares. How can I get ...
2
votes
2answers
174 views

Biopython installation

I have installed python-biopython and successfully used it in my python scripts with something like: import Bio But it eventually stopped working and now even after uninstallation and ...
1
vote
1answer
5k views

How to install Visual Python?

I'm a Linux newbie but I'm determined to get my favorite applications on my laptop running Ubuntu 12.04. I just installed Cinnamon. I'm trying to install Visual Python and it requires Python 2.7. I ...
0
votes
0answers
29 views

How to make Post Installation Script for automated installation?

I have a ks.cfg which automates xubuntu installation Now after installing I want to run a script which will install my code, my doing few things like copying ssh key from server and doing git ...
0
votes
1answer
44 views

remove gnome and install ubuntu-desktop

I accidentally un-install python from ubuntu. I had ubuntu desktop on it, and then I had to install gnome desktop. Now, I want to come back to Ubuntu-Desktop. I re install it, but when I log in, still ...
0
votes
1answer
48 views

How to make python scripts executable using cx freeze on ubuntu 14.04? [closed]

I want to convert my python project into a binary executable using CX Freeze on Ubuntu 14.04. How to do I run CX Freeze on Ubuntu???
2
votes
0answers
57 views

rubber failing after upgrade to 15.10

rubber is a program that compiles LaTeX files into pdf document. After upgrading, I receive the following error when trying to run rubber on a document. My apologies for the huge stack trace, but my ...
1
vote
0answers
276 views

ERROR: could not access file “$libdir/plpython2”: No such file or directory

I am running postgresql 9.4 ("PostgreSQL 9.4.4 on x86_64-unknown-linux-gnu, compiled by gcc (GCC) 4.1.2 20070626 (Red Hat 4.1.2-14), 64-bit" ) when I am trying to create language in postgres SQL : ...
22
votes
4answers
52k 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 ...
23
votes
4answers
11k 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?