Questions tagged [python-2.7]
Python 2.7 is a version of the Python programming language released in 2010. Use this tag for questions about using Python 2.7 in Ubuntu.
419
questions
0
votes
0
answers
17
views
Installing Cantera 1.8.0 on Ubuntu 18.04
I am trying a lot to install cantera 1.8.0. It is an older version but i need to install it on my Ubuntu 18.04. I am
Codeline of the error is
/usr/include/numpy/npy_1_7_deprecated_api.h:15:2: warning:...
0
votes
1
answer
440
views
Installing Azure Linux Agent gives python related issues
When I got this server assigned, it has two versions of python (2.7 and 3.6), then I had to install 3.10 manually because the version of Netbox I want to use needed 3.8 minimum.
Everything looked fine,...
0
votes
0
answers
175
views
RuntimeError: set scan parameters failed (are you root?)
I am trying to scan Bluetooth Low Energy devices around me. I have written a python script for it.
File Name: sample.py
*
from gattlib import DiscoveryService
service = DiscoveryService("hci0&...
0
votes
0
answers
355
views
FSL 6.0.6 installation on ubuntu 20.04 takes too much time
Why does FSL 6.0.6 installation on Ubuntu 20.04 take too much time?
It started good but stuck at 54% for nearly 9 hours. Since there was no error , I waited and got a message after approx 9 hours that ...
2
votes
0
answers
244
views
How to revert alternatives to default python2 on 18.04?
So on my 18.04 I upgraded my python3 to 3.7 (which build a meld dependency) and did this:
update-alternatives --install /usr/bin/python python /usr/bin/python3 1
which made the python command default ...
0
votes
0
answers
312
views
Python Package Error After Upgrading Ubuntu From 18.04 To 20.04
I have upgraded my Ubuntu Server OS to 20.04 from 18.04 with this command "sudo do-release-upgrade".
While upgrading, there was some problems with downloading packages for network problem.
...
0
votes
0
answers
121
views
gem5 compiling problems after adding python2.7 to my ubuntu
I had python3.8 originally, and compiled gem5 (X86 and ARM) successfully. then I added python2.7 to run some models. now I got below errors that I have not before when trying to compile gem5 using:
...
1
vote
1
answer
2k
views
Install python-mysqldb for Python 2.7 in Ubuntu 20.04 - unmet dependencies
I am trying to install python-mysqldb for Python 2.7 in Ubuntu 20.04:
$ sudo add-apt-repository 'deb http://archive.ubuntu.com/ubuntu bionic main'
$ sudo apt update
$ sudo apt install -y python-...
4
votes
2
answers
655
views
Running a Python2 program with Python3?
EDIT: Updates below, the scenery seems to have changed significantly.
I have Ubuntu 20.04, and have installed Python 3.10 manually. There's python 2 in the system already, and that's what I get if I ...
0
votes
1
answer
309
views
How to remove Python version shown in zsh terminal
How can I remove this "via python v2.7.17" from my terminal?
Sorry, I'm new to Ubuntu and I can't find any way to remove this from my terminal.
0
votes
0
answers
127
views
set up environment for python2.7, but "pip install ." gave error of the package requires a different python: 2.7.18 not in '>=3.7,<4.0'
(with Windows11 and currently using Ubuntu 18.04 LTS)
https://github.com/ding-lab/CharGer/blob/7d7d2911b89261fa5dceea6395a5d188a82757f2/README.md
I followed the instruction and created environment as ...
0
votes
1
answer
4k
views
How to change the version of python from 3.8 to 2.7
I need to use Python 2.7 in order to use PneumoCaT as it only runs with Python 2.7 not higher versions. I am trying to set my Python version from 3.8 to 2.7 in Ubuntu, but I can't do it.
This is the ...
0
votes
0
answers
246
views
Ubuntu 20.04 gnome tweaks not working with python 3.9
I recently upgraded my default python version from 2.7 to 3.9.
I updated and upgraded, everything working fine except the gnome-tweak is not working or not apprearing.
Any kind of information would be ...
2
votes
1
answer
3k
views
"No package 'pygtk-2.0' found" on Ubuntu 20.04 even after installing python-gtk2 from archives
I am trying to install blueman which seems to have pygtk-2.0 as a dependency.
When doing ./configure, it stops here:
configure: error: Package requirements (pygtk-2.0 >= 2.12.0) were not met:
No ...
0
votes
1
answer
651
views
I can't use python pip to download any tools and I don't know why
here's a picture of the error I get and the python installations i have, I tried to delete python7.2 and it seems like it's not working.. any help is highly appreciated
2
votes
0
answers
666
views
ykman installation
I tried installing ykman in ubuntu-18.04(WSL) using below commands,
sudo apt-add-repository ppa:yubico/stable
sudo apt update
sudo apt install yubikey-manager
when I try to find the version using: ...
3
votes
1
answer
4k
views
instaling matplotlib for python 2.7 in Ubuntu 20.04
I have to run some all programs written in python2.7. They use library "matplotlib". In the repository of Ubuntu 20.04 there is no candidate for installing it and matplotlib for python3 is ...
0
votes
3
answers
816
views
how do I remove python 2.7.16
I need to remove python 2.7.16 but even If I use: sudo apt-get purge python2.7 doing python --version still prints Python 2.7.16 I need to have python 3.6+. plz help
0
votes
1
answer
281
views
How to safely remove python2.7-dev and libpython2.7-dev from ubuntu 18.04?
Since a long time ago I had stopped development with python 2.7. As python 2 has been deprecated how can I safely remove python2.7-dev and libpython2.7-dev from my system.
Can I simply do
sudo apt ...
0
votes
1
answer
495
views
Uninstalling Python 2.7.12 on ubuntu 18.04 ended with broken packages [duplicate]
I made a hoorible mistake because I removed pyth 2.7 of my ubuntu machine 18.04 as I wanted to keep only python3 but unfortunately there were some componenents who were installed using pip from the ...
0
votes
1
answer
5k
views
neither python 3 nor python 2 works well on ubuntu 18.04 with repo?
I'm on ubuntu 18.04 and I'm trying to init this repo :
# repo init -u https://github.com/anbox/platform_manifests.git -b anbox
since I'm using this version of python :
# python
Python 3.6.9 (default, ...
4
votes
2
answers
6k
views
“pip install MySQL-python” not working on Ubuntu 20.04
When I try to install MySQL-python using pip for Python 2.7, it is not working anymore on Ubuntu 20.04 - on Ubuntu 18.04 it still works...
Any idea of how I could make this run on Ubuntu 20.04?
I know ...
1
vote
2
answers
14k
views
pip 2.7 error `sys.stderr.write(f"ERROR: {exc}")`
I'm using docker image of Ubuntu 16.04 ros:kinect container.
My problem is that when I upgraded pip 2.7 (python version Python 2.7.12) via sudo pip install pip --upgrade, it started to show the ...
1
vote
1
answer
541
views
I have several python versions installed and I want to remove the packages installed under them [duplicate]
Using pip I am only able to uninstall for a few versions. I am fairly new to this, so please let me know if there is some way of deleting it. I am currently using Ubuntu 20.04. I had previously ...
1
vote
1
answer
896
views
error updating python 2.7.12 on xenial [duplicate]
I did the following but still fail to update the python2 to the latest build
sudo apt update
apt list --upgradable
Listing... Done
libpython2.7/xenial-updates,xenial-security 2.7.12-1ubuntu0~16.04.14 ...
0
votes
0
answers
153
views
how to resovle confusing pip and pip3 in ubuntu?
Using Ubuntu 20.04, I checked my python and pip version which are:
python -V:
Python 2.7.18
python3 -V:
Python 3.8.5
which python
/usr/bin/python
which python3
/usr/bin/python3
pip -V
pip ...
5
votes
1
answer
5k
views
Ubuntu 20.04 - need Python 2 - native Python 2 install vs other options?
I've been using Ubuntu 20.04 for a few months now and things are going well, however recently I ran into 2 legacy applications which I'll need to start supporting that will require Python 2. As best ...
0
votes
1
answer
203
views
Dependencies of python2, e. g. GIMP
After installing in 18.04 (upgraded from 16.04) python3 I removed python2 by
sudo apt autoremove python2
sudo apt autoremove python2.7
As I now realized this was stupid.
But I don't understand why ...
-1
votes
1
answer
1k
views
Why is my docker file assuming Python 2.7?
I am working on a pc with ubuntu 20.04.1 LTS
My python version is 3.8.5
I am trying to build a docker image with the following Dockerfile
FROM ros:kinetic-robot
LABEL maintainer="olala7846@gmail....
0
votes
1
answer
192
views
I need to execute my python code on raspberry pi 4 automatically, in Every per minute [duplicate]
I entered this command to execute:
* * * * * python/home/pi/Desktop/sensor.py >> /var/log/gasdetails.log 2>&1
but it gives an info:
Dec 22 21:08:01 raspberrypi CRON[2070]: (CRON) info (...
0
votes
2
answers
1k
views
Trying to update python3.9 giving errors
What I've done :
sudo add-apt-repository ppa:deadsnakes/ppa
sudo apt update
sudo apt install python3.9
sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.8 1
sudo update-...
4
votes
2
answers
15k
views
How to create python2.7 virtualenv on Ubuntu 20.04
I want to run an application that uses python2.7 version, but by default python2.7 is not installed. When I tried to use:
$ virtualenv -p python2 flaskold
It returned:
RuntimeError: failed to find ...
0
votes
1
answer
355
views
Pycharm Community Edition isn't detecting my packages
I have tried and tried again to properly install a package for Pycharm. I've used pip for both Python2.7 and Python3, and I've tried to use the tar file. But Pycharm doesn't detect the modules, even ...
2
votes
1
answer
5k
views
sh: 1: python: not found when execute python script from php
I'm tring to execute a python script call from php with the command below:
$output = shell_exec('python /var/www/html/sna/server/userManagement.py '. $user.' '. $pass .' \''.$action.'\' 2>&1');
...
0
votes
0
answers
3k
views
How can I solve a "module not found" error when running python scripts?
Preface
This is most likely a question which has been asked before but alas, none of those previous have been able to provide a conclusive answer/fix.
Actual issue
I'm trying to run a script which ...
1
vote
2
answers
2k
views
How to update system python 2.7 to 3.x in Ubuntu 20.x after upgrade
I have an old VM that started out as Ubuntu 16.x then I upgraded it to the 18x series and now 20.x series. I was surprised that python 2.7 was still the system python.
I discovered that if you upgrade ...
0
votes
0
answers
67
views
Installing python 2 deb packages locally in a single project
I am struggling with cutting off python 2 functionalities from ubuntu 20. I have a project that porting to python 3 may take a lot of time so i have to use ubuntu 18 packages to satisfy its module ...
0
votes
1
answer
2k
views
ModuleNotFoundError: No module named 'pandas' occurs even if pandas is installed on my machine
I am using Ubuntu 16.04. I have python 2.7 and python 3.7 installed on machine.
I have installed pandas on my machine.
However when I try to import the pandas package it gives ModuleNotFoundError: No ...
2
votes
1
answer
2k
views
Ubuntu 20.04 ImportError: No module named gdal
I am trying to use python2 bindings for gdal on Ubuntu 20.04 LTS, which does not have the python-gdal package in it's repository, to run an old python2 application.
I tried to download and install it ...
3
votes
1
answer
6k
views
Ubuntu 20.04 ImportError: No module named gtk.glade
i am trying to launch an old python2 script. On ubuntu 18.04 i installed python-glade2 and it worked, unfortunately ubuntu 20.04 doesn't have it in repositories. Is there a way to get this gtk.glade ...
5
votes
2
answers
7k
views
How to get PyQt5 for Python2 on Ubuntu 20.04
I have a critical PyQt5 application which is still in the migration to Python3 phases.
K/Ubuntu 20.04 has removed the required packaging to install PyQt5 for Python 2.7. I understand the importance ...
1
vote
1
answer
304
views
How to make python2 find the old python-gtop?
I'd like to install python-gtop from the old
python-gtop_2.32.0+dfsg-1_amd64.deb
but that has a dependency on python (< 2.8)
The following packages have unmet dependencies:
python-gtop : Depends: ...
1
vote
1
answer
677
views
Uninstalled python2, but still appears in /usr/bin and in file explorer
I am trying to uninstall Python 2. I have attempted to do this both from my computer's Control Panel and from the Ubuntu command line using sudo apt remove python2. Both of these actions appear to ...
1
vote
0
answers
239
views
Ubuntu 18.04-Runtime error- Embedding python to C
I am working on a project which is related to object detection and ocr. I am using Ubuntu 18.04 and python 2.7, yolov3 for object detection and tesseract 5.0.0-alpha-692-g62ea for ocr. I have to embed ...
1
vote
0
answers
113
views
python38, python3, python 2.7, and python 3.8, a file called "secretstorage" and some serious file differences
I have Xubuntu based on 20.04. A newish install. My security is a VPN and the firewall from the router.
I have python2.7, python3(no decimal), and python3.8. python3 is VERY different from the ...
4
votes
2
answers
2k
views
How to get the terminal to work again? Terminal stopped working after changing default python version
I was trying to make python version 3 as a default version of Ubuntu,
I used nano ~/.bashrc and added the first line of this answer.
Then It just messed up my terminal.
Now when I am clicking on ...
13
votes
2
answers
32k
views
How to remove Python 2 from Ubuntu 20.04?
I've upgraded recently from Ubuntu 18.04 to 20.04. But I can see that Python2 is still the default instead of python 3.8.2.
$ python -V
Python 2.7.18rc1
$ python3 -V
Python 3.8.2
Is it possible ...
0
votes
1
answer
2k
views
pip install pyopenssl object has no attribute 'SSL_ST_INIT'
I've searched this forum for the same issues and none of the fixes worked for me. I have a Ubuntu 18.04 and any python 2.7 modules that need OpenSSL I get an attribute error. Pip install command ...
1
vote
1
answer
924
views
How to install gcloud in a Docker container on 19.10?
I have a Docker container as 19.10 as both the host and guest, and I tried to install gcloud:
# Add the Cloud SDK distribution URI as a package source
RUN echo "deb [signed-by=/usr/share/keyrings/...
2
votes
1
answer
2k
views
Is there a way to get Blue-Proximity working or an alternative?
I'm looking for a way to use my mobile to automatically unlock my laptop. Blue Proximity seemed like a good answer, but it's clearly been abandoned as a project and I'm having problems with some of ...