Questions tagged [python]

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.

Filter by
Sorted by
Tagged with
3 votes
2 answers
901 views

x-tile / python-gconf not installable on 18.10 MATE

On 18.10 MATE I'm trying to install x-tile https://www.giuspen.com/x-tile/ which I've been using since 16.04 or so. Installation fails looking for python-gconf and installation of python-gconf fails ...
Stephen Boston's user avatar
0 votes
1 answer
3k views

fatal error: Python.h: No such file or directory [duplicate]

I am trying to install cocoapi but I do not have Python.h. I read that I need to install python-dev but I do not have sudo. Are there any other easy ways to get Python.h? Will I get Python.h if i ...
Kong's user avatar
  • 1,221
2 votes
2 answers
16k views

how to upgrade pip to version >> 9.0.1 ? (pip install --upgrade pip gives 'cannot import name main' error)

I have pip 8.1 installed and I wanted to upgrade to > 9.0.1 (to install matplotlib for python 2.7). I saw How to upgrade pip to latest? and did sudo -H pip3 install --upgrade pip sudo -H pip2 ...
Chan Kim's user avatar
  • 1,969
0 votes
1 answer
5k views

How can I use pip to install python packages for python3? [closed]

I don't have enough space on my computer to install Anaconda. First I install python3 using this: sudo apt install spyder3 after that, for installing a package, I use this in terminal: pip install ...
user3467834's user avatar
4 votes
1 answer
278 views

How do I set PYTHONASYNCIODEBUG value in pipenv python?

I am running python 3.6 in a pipenv shell. I want to set the value of this python environment variable PYTHONASYNCIODEBUG to 1 without affecting my user environment variables that are outside of the ...
Sun Bear's user avatar
  • 2,284
0 votes
2 answers
2k views

Calculation percentage of my data for different number ranges [closed]

I am trying to find out how to calculate percentage of my data for different number ranges. So I have a data that looks like this: 0.81761 0.255319 0.359551 0.210191 0.374046 0.188406 0.179487 0....
sergio's user avatar
  • 135
1 vote
0 answers
434 views

IDLE for Python 3.6 can't open .py files on Ubuntu 18.04

I just did a clean install of Ubuntu 18.04. I downloaded pip3, python 3.6.7, discord.py, and IDLE for python 3.6. When I go to open up .py files I have on my other computer, I don't have to option ...
TexasZeEdiot's user avatar
0 votes
0 answers
439 views

Trouble with python on Ubuntu 14.04

I'm using ubuntu 14.04 and I have messed up python. First, I've installed python 3.6.8, but I had some problem with it, so I moved to python 3.6.1. Only way to invoke 3.6.1 version is to use python3.6,...
Zeden's user avatar
  • 1
1 vote
0 answers
78 views

How to update a debian package for a python program with a setup.py

For the first time, the command dh_make will create all necessary files and directories and this can be packaged with debuild -S. After I make some changes, am I supposed to manually update the ...
Archisman Panigrahi's user avatar
0 votes
1 answer
606 views

problem with the installing NS-3

I am trying to install NS-3 on my Ubuntu 16.04 and I have a strange problem. I installed all the prerequisites for ns3 and its time to install ns3 itself. I'm installing it through the bake,(https://...
Mustafa's user avatar
2 votes
0 answers
2k views

Connection to Python debugger failed: Accept timed out

I have issues with attaching to process on ubuntu 18.04.2 LTS, Python 2.7.15rc1. I set up system: kernel.yama.ptrace_scope = 0 When I'm trying attach to process I get timeout error (I can see ...
tstr's user avatar
  • 141
0 votes
0 answers
34 views

some crontab job not working , not all

I have a python job need to run every day It need start_date and end_date parameters, so I use date . The command didn't work at first, but no problem when executed in shell: 0 7 * * * /usr/bin/...
Mithril's user avatar
  • 2,381
0 votes
0 answers
75 views

cron job decides for itself if it wants to run

I recently wrote a python script that reminds me via email if I need to move my car for the street sweeper mafia (and avoid a ticket). When I ran the script from the command line, it worked every time....
Robert Baker's user avatar
3 votes
1 answer
7k views

How to run Django cron in crontab?

I have a Django application which uses django-cron (https://django-cron.readthedocs.io/en/latest/installation.html), and I need to execute python manage.py runcrons every 5 mins in AWS EC2 running on ...
Vince Gonzales's user avatar
1 vote
1 answer
2k views

python 3.7 on Ubuntu 16.04

I have tried to install python 3.7 on my ubuntu 16.04 via this link. It is Installing it without any error and it returns : which python3.7 /usr/local/bin/python3.7 Also I have other python ...
Haribo's user avatar
  • 111
1 vote
0 answers
629 views

rosdep has unmet dependencies

My synaptic manager gives me an error saying that python-rosdep is broken in my system. So I did the following: Edit->Fix broken packages->Apply. But I get an error: E: /var/cache/apt/archives/...
Surabhi Verma's user avatar
8 votes
1 answer
9k views

Installing python modules fail - "limits.h" missing?

I am trying to install a number of python 3 modules (e.g. regex, cytoolsz, spacy) that require compilation, but they all fail with an error identical to the below (bottom). I have tried to check for ...
mac's user avatar
  • 250
1 vote
0 answers
556 views

Can't install Python mysqlclient bindings [duplicate]

I'm running 64 bit Ubuntu 18.04. Although I got it working on my work machine (Ubuntu 18.10 64 bit), I simply cannot get the MySQL client Python libraries working on my personal machine. It's well-...
Jack M's user avatar
  • 1,310
0 votes
0 answers
537 views

How to insert data into mysql using loop back

I'm done loopback and mysql connection, But i don't know how to insert the data in to tables. Can anyone help me? DB connection "mysqlds": { "host": "localhost", "port": 3306, "url": "", ...
Karthick Selvakumar's user avatar
0 votes
0 answers
163 views

Recovering from botched install of Pip3, Ubuntu 16.04 LTS

I think need to have the latest version of PIP3 for building the latest version of a program from source, so when I ran PIP3 and couldn't build the program, I upgraded it like it suggested, and now it ...
Will Matheson's user avatar
0 votes
1 answer
69 views

How to create an auto delete video

Can anyone tell me how to create an auto delete/self destruction video in PC/Pen drive? I'm doing a project and its very important to keep my data confidential... Could you please help me?
R Krish's user avatar
0 votes
3 answers
7k views

No module named numpy

I am trying to run Jupyter notebook from my Ubuntu subsystem in Windows 10. I've installed numpy, scipy, and pandas using the following commands: pip install scipy numpy pip install pandas When I ...
SayMyNameHeisenberg's user avatar
0 votes
1 answer
2k views

How to set vs code for python3

I recently bought a new laptop and installed ubuntu. I messed around with bash and learned that I there is a default python interpreter. However, the biggest problem that I face is that I can't get it ...
Silver Flash's user avatar
0 votes
1 answer
90 views

Is it possible to open terminal from run box and use ' -- ' to run a command to pen a file in some other directory?

What i want to do is to start a terminal session with the python command line interpreter and and further run a python file using the interpreter the python file could located anywhere. What i mean ...
user8157045's user avatar
0 votes
0 answers
298 views

Install GDBM when apt is not working

I am trying to update my 16.04 to the latest 18.10. But this caused a relocation error with the package libapt-pkg.so. This naturally makes my apt useless. To overcome that I am following the advice ...
Anuroop Kuppam's user avatar
0 votes
1 answer
119 views

python 3 shambles

First of all on my 18.04 LTS machine I have Ubuntu update issues , several updates have been botched todays update too, nevertheless my updater says everything is up to date Iḿ not sure if python ...
Derek Giroulle's user avatar
0 votes
1 answer
778 views

How to resolve 'held broken packages' (python)?

Unable to install pip , getting error E: Unable to correct problems, you have held broken packages. details: uname -a Linux a123-45-678-90 4.4.0-116-generic #140~14.04.1-Ubuntu SMP Fri Feb 16 09:25:...
StackGuru's user avatar
  • 101
-2 votes
1 answer
5k views

What is the best tool to add a GUI to Python code and make a Linux application from it? [closed]

I am learning Python. What is the best tool to add a GUI to Python code and make a Linux application from it? Something that is easy to learn but powerful. I found something like PyGTK, Tkinter or ...
zkosmosu's user avatar
0 votes
1 answer
465 views

install python module for certain python binary

I am using ubuntu 16.04 and have installed python2 and python3. Default is python2. I am trying to install a python module (mapscript) with this command sudo apt-get install python-mapscript ...
xpanta's user avatar
  • 1,491
6 votes
2 answers
34k views

Remove old versions of Python and pip

I recently updated from Ubuntu 16.04 to 18.04. I had separate partitions for / and home, and for the update I made a clean install over the / folder, so that I saved everything in the home folder, ...
Carlo's user avatar
  • 203
1 vote
1 answer
2k views

ImportError: cannot import name Eog, introspection typelib not found

I am trying to get the eye of the gnome plugin demo working from here. I have installed the dependencies, but on the line from gi.repository import GObject, Eog, Eog cannot be found. If I go to the gi....
jackw11111's user avatar
1 vote
1 answer
187 views

In ubuntu IDE doest load tkinter library for python3 or python2

Hello everyone and thank you for your help in advance. I am trying to use tkinter library. When I open terminal type python3 and use import tkinter tkinter._test() It works. Also when I type ...
Boris Šípoš's user avatar
7 votes
3 answers
7k views

How can I fix terminator? It doesn't work

When I run terminator in terminal, it doesn't work. The error is this: $ terminator File "/usr/bin/terminator", line 119 except (KeyError,ValueError), ex: ^ ...
Alex Seo's user avatar
3 votes
1 answer
9k views

Activating conda environment in "startup applications" script

So I have a python script that generates an animation - and it requires libraries that I have in a conda environment. I need to run this script as soon as my computer turns on, so I've written a short ...
Robbie Barrat's user avatar
1 vote
1 answer
654 views

Automatically run graphical python script on startup

I have a python script that starts a fullscreen animation when run - how do i set this to start at startup in ubuntu 16.04? Other answers to the "script on startup" problem don't work - because I'm ...
Robbie Barrat's user avatar
0 votes
1 answer
709 views

Create shortcut for electrum bitcoin wallet

I installed Electrum bitcoin wallet from electrum.org but don't know how to launch it or create a shortcut for it. These are the commands I used: Install dependencies: sudo apt-get install python3-...
Dr.Joe's user avatar
  • 11
0 votes
2 answers
7k views

Cannot import Numpy and Pandas

I have installed numpy and pandas using pip. After executing my python code it shows the following error: Traceback (most recent call last): File "demo.py", line 1, in <module> import ...
Tauhid Khan 's user avatar
1 vote
0 answers
538 views

Deja dup backup fails

Backing up using Deja Dup to an external drive is failing, it used to work fine. Last backup was 43 days ago. When I attempt to backup, Deja Dup decides to do a full fresh backup not incremental. At ...
Matt Swan's user avatar
2 votes
0 answers
372 views

multiple python versions after pip3 install

I've spent a lot of time on the internet but did not found the information I need. I've installed sudo apt-get install python3-pip from shell (I needed it for Pycharm venv - not important) but it ...
Vitaliy Terziev's user avatar
1 vote
3 answers
2k views

Tensorboard using Python 2.7, how to change it to Python 3?

So I program a tensorflow program in python3, and can execute said scripts with python3, with the modules that I installed using pip3. But when using tensorboard --logdir="./graphs" --port 6006 It ...
TrackLab's user avatar
12 votes
1 answer
6k views

Sending pause/resume playing and next/previous track bluetooth commands

I would like my Ubuntu PC sending bluetooth audio commands (play/pause, next/previous song and turn up/down) to other device streaming music over bluetooth to it. In other words, I would like to ...
pt12lol's user avatar
  • 301
0 votes
0 answers
193 views

Can't find module tkinter after exporting code from Jupyter

I exported a file from Jupyter to a .py format. The code works fine on Jupyter itself, but when I try to run it directly from the command line I get the following error Traceback (most recent call ...
pfreire's user avatar
-1 votes
2 answers
7k views

Cannot uninstall python on Ubuntu? [duplicate]

I have confused to uninstall python3 or fix my VPS Ubuntu Im using Ubuntu 16.04.5 LTS (GNU/Linux 4.4.0-31-generic x86_64) I tried to uninstall all python packages sudo apt-get purge python3 And ...
katro coplax's user avatar
0 votes
2 answers
1k views

import caffe on python2.7 - ubuntu 18.04 LTS

On ubuntu 18.04 LTS, Caffe-cpu can install by.... sudo apt-get install caffe-cpu ... but it fails when I import on python2. It can only import on python3. How to import caffe on python2? I tried to ...
Yang's user avatar
  • 95
1 vote
1 answer
4k views

Why won't scikit-image work for Python3?

So I'm trying to use scikit-image for several functions on images. One such function is converting an image from rgb to hsv where I took my image (img) and said from skimage.color import rgb2hsv ...
Brandon MacLeod's user avatar
1 vote
1 answer
2k views

ModuleNotFoundError: No module named 'pandas' (only as root)

So I'm having this weird issue. I just installed server 18.04.1 LTS. The purpose of this server is to run scheduled Python scripts. I can run my script just fine when authenticated with the user-...
Michael DeYoung's user avatar
2 votes
1 answer
14k views

How to update a Python package which was installed by pip

According to The Ubuntu lifecycle and release cadence, Ubuntu 16.04 has full support until mid-2021. Yet when I run: pip install cryptography it says: Requirement already satisfied: cryptography in /...
Luis's user avatar
  • 133
2 votes
1 answer
200 views

Orca - Cannot save configuration

I'm trying to change the voice person on the orca setup (orca -s) and when I try to click the buttons 'Apply' or 'OK' this error shows up in the console: Gtk-Message: 12:48:35.589: GtkDialog mapped ...
shulito's user avatar
  • 123
4 votes
2 answers
12k views

Unable to install python cryptography module

I have a python program with the line from cryptography.hazmat.backends import default_backend When run with python3, I get the error ModuleNotFoundError: No module named 'cryptography' I ...
sayanel's user avatar
  • 367
1 vote
1 answer
1k views

How to access "python3.6/site-packages" directory?

So right now I am trying to import tflearn on a python script, but that returns the error AttributeError: type object 'numpy.ndarray' has no attribute '__array_function__' (Theres a huge error ...
TrackLab's user avatar

1
34 35
36
37 38
104