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.

Filter by
Sorted by
Tagged with
-1
votes
0answers
321 views

Python 2.7 built from source unable to import packages

I have an Ubuntu 14.04 VM running Python 2.7.6. 14.04 and Python 2.7 are requirements for what I'm working on, but I need to upgrade to a newer version of Python 2.7 because pip packages are failing ...
0
votes
1answer
28 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
1answer
72 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
1answer
391 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, ...
2
votes
0answers
434 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 ...
0
votes
0answers
132 views

“pip2 install psycopg2” gives an error - help

I am using anaconda3 and python 3. There is a project which uses python2 and pip2. When pip2 install psycopg2, this error pops up? Any help? Traceback (most recent call last): File "/usr/local/...
1
vote
2answers
5k 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
1answer
153 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
1answer
491 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
0answers
47 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 ...
0
votes
0answers
43 views

Default Python Interpreter Error

While trying to ping the node machine from the ansible controller it shows like this . Any ideas to solve the issue. Version Oracle 7 192.168.0.107 | FAILED! => { "ansible_facts": { &...
4
votes
1answer
1k 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
1answer
35 views

Dependencies of python2, e. g. GIMP

After installing in 18.04 (upgraded vom 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
1answer
101 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
1answer
97 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
1answer
185 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-...
1
vote
1answer
2k 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
1answer
32 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
1answer
2k 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
0answers
1k 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 ...
0
votes
0answers
31 views

Problems running ldtp in an ubuntu docker container

I'm trying to run ldtp 3.5 inside an ubuntu docker container. My Dockerfile looks like this: FROM ubuntu:18.04 ENV XAUTHORITY ~/.Xauthority RUN apt-get update -y && \ apt-get install -y ...
0
votes
2answers
68 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
0answers
39 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
2answers
894 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 ...
1
vote
1answer
1k 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 ...
1
vote
1answer
3k 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
2answers
4k 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
1answer
234 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
1answer
181 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
0answers
147 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
0answers
43 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 ...
3
votes
2answers
688 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 ...
0
votes
0answers
731 views

pgadmin4 installation error [Errno 2] No such file or directory

I am trying to install pgadmin4 on my Ubuntu 20.04 focal. I followed this link: https://linuxhint.com/install-pgadmin4-ubuntu/ . This website contains installation in two ways, one from the steps ...
4
votes
2answers
10k 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
1answer
735 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
1answer
461 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/...
1
vote
1answer
609 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 ...
0
votes
1answer
60 views

Python command target changed

Older versions of Ubuntu shipped with python 2.7 and python 3.6. But in Ubuntu 20.04 LTS, only python 3.8 is installed. So when python was typed in terminal, python3.8 opened. python, python3 and ...
1
vote
1answer
1k views

Python3 vs Python 3.8

Ubuntu (older than 20.04 LTS) ships with Python 3 and python 2 both. When python was typed in terminal, python2.7 opens and to open python 3.6, python3 command is needed. However python3.6 also works. ...
0
votes
1answer
2k views

`pip install pygame` produces `Command “python setup.py egg_info” failed with error code 1 in /tmp/pip-build-vD9diA/pygame/`

What I'm running on OS: Ubuntu Server 18.04.4 Computer: Raspberry Pi 4 Model B pip version (the default installed on 18.04.4 LTS): pip 9.0.1 python version (the default installed on 18.04.4 LTS): ...
8
votes
1answer
9k views

pygtk not available on Focal Fossa (20.04)? [duplicate]

tl;dr I cannot install pygtk on Focal Fossa (Ubuntu 20.04) anymore but need it for my self-written PyGTK-based Python application. I wrote a Python2 application some years ago based on GTK using the ...
1
vote
0answers
620 views

Can't import installed package in python

I've Installed Charm-Crypto in my ubuntu 18.04 and I can find this library files in /usr/lib/python2.7/dist-packages path. But when I try to import this library I'm getting this error message: Python ...
0
votes
1answer
3k views

python2-requests package missing in Ubuntu 20.04?

I do not see any package named python2-requests in the apt search results. I do not see pip2 either. How can I install requests module for python2 ?
0
votes
1answer
46 views

Make file wrong for building libbot2 library

Let me describe my problems. So far I was building the MPNet which requests the libbot2 library. MPNet GitHub libbot2 GitHub I have installed the requirement libraries as followed: GLib 2....
1
vote
1answer
195 views

Python version ambiguity on ubuntu 18.04 & ubuntu 20.04

I can't comprehend what mess I am in, somebody please explain what is happening here and how do I resolve it?screenshot of command line $ python --version Python 3.6.5 $ which python /usr/bin/python ...
1
vote
3answers
3k views

Ubuntu 20.04 still supporting Python2

I upgraded from Ubuntu 19.10 to 20.04. Many articles mention that the latest LTS will not support python2. But I still have it. Why is that? $ python Python 2.7.18rc1 (default, Apr 7 2020, 12:05:55) ...
2
votes
2answers
3k views

Can Gourmet still run on Ubuntu 20.04?

I am a Gourmet user for my cooking recipes, I found no better alternative on Ubuntu for that. Gnome Recipes is attractive and promising, but dev is not very active from what I can see, and it lacks ...
0
votes
0answers
393 views

Error after the installation of python-pip

I have Ubuntu (version 18.04.4), installed on Windows, if it is important. Python version is 2.7.17. I'm installing pip with sudo apt install python-pip and the output looks ok, but when I'm ...
2
votes
1answer
327 views

Does python on Ubuntu come with any libraries?

I'm asking this because it appears to me that the standard Ubuntu installation already comes packaged with the python library requests (although I could be wrong about this). Is there a list of, if ...
0
votes
1answer
83 views

Cannot install ocrfeeder on Ubuntu 18.04

ocrfeeder is an Ubuntu desktop application which utilises Tesseract and other OCR engines to perform OCR. I had it running OK under Ubuntu 14 but am having problems installing it under 18.04. Problem ...

1
2 3 4 5
9