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
1
answer
146
views
Installing python 3 modules issues
I am having an issue installing modules on OS Ubuntu 19.04 with Python 3.7.3 and Python 2.7.16
The module is only for Python>=3.5.
Research hasn't led me to much or I have looked in the wrong places ...
1
vote
1
answer
2k
views
The package "software-properties-gtk" needs to be reinstalled, but I can't find an archive for it
I'm using ubuntu 16.04.
Whenever I tried to install new package,
"The package software-properties-gtk needs to be reinstalled, but I can't find an archive for it."
this error is occurred:
Thanks....
0
votes
1
answer
6k
views
How to install pygame in python 2.7.6 on ubuntu 14? [duplicate]
How can I install pygame in python 2.7.6 on Ubuntu 14? I've used sudo apt-get install python-pygame, but it does not work and gives me the following message: unable to locate package python-pygame. ...
1
vote
1
answer
236
views
Which of these Python 2.7 libraries can I remove without bricking my 16.04?
I am trying to remove all non-system Python 2.7 libraries which I installed in my 16.04. I want to reset my Python library list to its default.
I have manually removed most of the libraries myself ...
2
votes
2
answers
6k
views
add-apt-repository: Problem with the SSL CA cert
user@amd64:~$ sudo add-apt-repository ppa:jd-team/jdownloader
[sudo] password for 1:
Traceback (most recent call last):
File "/usr/bin/add-apt-repository", line 125, in <module>
ppa_info =...
0
votes
1
answer
2k
views
Problem when installing pip for python 2.7.16 in Ubuntu 18.04 [duplicate]
I used the following in Home
$ sudo apt install python-pip
the output was the following
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages ...
2
votes
0
answers
8k
views
What's the command to find out version of gcc is used inside a conda virtual environment?
I have a program to be compiled in which I need to have gcc.
However, when a python 2.7 virtual conda enviornment being installed, it needs gcc. So I believe I don't have to install gcc package ...
6
votes
2
answers
12k
views
Unable to install VMware Horizon Client on Ubuntu 18.04
sudo sh ./VMware-Horizon-Client-4.8.0-8518891.x64.bundle
Extracting VMware Installer...done.
/tmp/vmis.bxQxOU/install/vmware-installer/vmware-installer: line 76: python: command not found
Edit:
I ...
0
votes
0
answers
112
views
Kivy doesn't works with Python3 but works with Python2
I installed the Kivy library for Python3 but when I import the Kivy library, the interpreter gives an error 'No module name Kivy' even though I installed the package python3-kivy. I'm able to import ...
1
vote
0
answers
1k
views
How to reset pip packages of python2 and python3 to the default in 16.04?
I want to reset all the python modules in python3 and python2 to the default system packages in 16.04. I followed this method pip freeze | grep -v "^-e" | xargs pip uninstall -y which broke my pip and ...
0
votes
1
answer
482
views
FailedPreconditionError: /home/timucin/Thesis/Tagger-master8/train; Is a directory
I received the following error:
FailedPreconditionError: /home/timucin/Thesis/Tagger-master8/train; Is a directory
[[{{node input_queues/examples_queue/parallel_read/ReaderReadV2}} = ...
0
votes
2
answers
125
views
Get an error when i try to open application from Python
if "open" in text:
app = text.split(" ", 1)
self.respond("opening " + app[1])
os.system("open -a " + app[1] + ".app")
get this error
open: invalid option -- 'a'
Usage: open [...
1
vote
1
answer
5k
views
unable to import pcl to python?
I followed the instructions given here http://www.pointclouds.org/downloads/linux.html .
After installing the libpcl , what should be done to import it in python?
1
vote
2
answers
2k
views
Switching between Python 2.x and 3.x in Linux machine
I am having two code bases build_2.x and build_3.x which were coded in python 2.x and python 3.x respectively.
I have a Linux machine in which Python 2.x is installed, but for my project purpose I ...
1
vote
1
answer
24k
views
Python 3 as default Python command [duplicate]
I am using Visual Studio Code for my Python programming and the problem that I am facing is that on terminal when I type the command python, by default Python 2.7 is loaded. So because of this I am ...
2
votes
1
answer
468
views
What happens to Python 2.7 if I upgrade Ubuntu 16.04 to 18.04?
I do not want to have two versions of Python on my computer and the version that I want is 2.7.
I (today) installed Ubuntu 16.04 so that I would have Python 2.7, but (possibly because 16.04 is older ...
20
votes
5
answers
68k
views
How do I switch back to python2 after Anaconda set python3 as the default?
Recently, I installed Anaconda3-2.5.0-Linux-x86_64.sh on my 15.04 and ended up with this!
:~$ python --version
Python 3.5.1 :: Anaconda 2.5.0 (64-bit)
:~$ python2 --version
Python 2.7.9
:~$ python3 ...
0
votes
0
answers
687
views
After installing Python3.7 -> "A problem occurred when checking for the updates"
I recently installed Python3.7, and after that a red icon (stop sign) appears in my task bar with the message "A problem occurred when checking for the updates".
As far as I could inform myself, ...
0
votes
1
answer
25k
views
cv2.error: (-215) size.width>0 && size.height>0 in function imshow
import cv2
import numpy
cap = cv2.VideoCapture("test1.avi")
while 1:
ret, frame = cap.read()
cv2.imshow("cap", frame)
if cv2.waitKey(100) & 0xff == ord('q'):
break
cap....
4
votes
0
answers
1k
views
Ubuntu 18.04 dpkg/apport problem
I recently updated python2 on my system, and now whenever I attempt to update or install any packages, I get an error of the following sort:
sudo apt-get install -f
Reading package lists... Done
...
0
votes
1
answer
3k
views
Package management broken, many "[Errno 2] No such file or directory" errors [duplicate]
Yesterday I had been trying to update intel drivers and rebooted. I don't remember or have the commands I had used but since the reboot I have been unable to install any software or attempt to fix my ...
-5
votes
1
answer
114
views
Why does the Ubuntu Software Center use Python 2?
The Ubuntu Software Center is described as,
Utility for browsing, installing, and removing software
Ubuntu Software Center lets you browse and install thousands of
free and paid applications ...
0
votes
2
answers
12k
views
i installed python cv but error showing no module named cv2
Traceback (most recent call last):
File "", line 1, in
ImportError: No module named 'cv2'
How to fix this error
1
vote
1
answer
10k
views
ImportError: No module named easydict
I'm trying to run the demo of py-faster-rcnn based on this GitHub page.
I have done all the previous steps. But When I try to run the demo with python ./tools/demo.py --gpu 0 --net vgg16 I get this ...
1
vote
1
answer
2k
views
Python syntax error with awk, sprintf statment (2.7)
I am trying to use one of the shell commands to a python script, but struggling with some syntax error here.
The description of the command is from here
echo /dev/bus/usb/`udevadm info --name=/dev/...
0
votes
1
answer
157
views
Does opencv3 support measurementMatrix attribute for kalman filter?
I am using Ubuntu 16.04, python 2.7.12 and I have installed opencv 2.4.9.1 version. I am trying to run a code for kalman filter and I get the following error:
AttributeError: 'cv2.KalmanFilter' ...
1
vote
0
answers
456
views
Take pictures automatically from mobile camera and use it as a web cam
I have found a python script which can automatically capture my photo through web cam. My web cam quality is far inferior and I need superior quality photo because I wanna use that for image ...
3
votes
1
answer
792
views
Will it be safe to use python 2.7 on Ubuntu 18.04 after python 2 EOL?
Ubuntu 18.04 will still be supported after 2020, yet python 2.7 will reach its end of life. If a CVE or a bug raises for python 2.7 after 2020, will the Ubuntu package get an official fix (through APT)...
3
votes
1
answer
2k
views
rpy2 installation errors
I am trying to install rpy2 but keep running into installation errors. I have found another post that had similar problems:
https://stackoverflow.com/questions/27136523/rpy2-installation-error-os-...
3
votes
1
answer
769
views
How to repair a broken apt-btrfs-snapshot in kubuntu 18.04?
After installing Kubuntu 18.04 on a Thinkpad W520 on btrfs over LUKS I came to the activation of the automatic APT snapshots. Here it shows up that any call of apt-btrfs-snapshot crashes, complaining ...
1
vote
1
answer
497
views
Cannot use Python apps after Ubuntu 18.04
After updating to Ubuntu 18.04 LTS I can no longer use most Python apps including pip (to install or uninstall). I get the following error in command-line:
Traceback (most recent call last):
File ...
4
votes
0
answers
320
views
Accessibility bus error when packaging
When i do quickly package i get the flowing warning. Not a big deal but because this warning i can't share my package to my ppa.
** (setup.py:5679): WARNING **: Couldn't register with accessibility ...
3
votes
1
answer
9k
views
Tostring() has been removed. Please call tobytes() instead
I try to install Reddit on my ubuntu server but I get an error after "make" line.
Please see the all lines from the server.
[+] including definitions from Makefile.py
python setup.py build
Cannot ...
0
votes
1
answer
96
views
Unable to uninstall anything or due to Python 2.7 error [duplicate]
I am not able to uninstall any program on Ubuntu due to a Python config error.
Some googling led me to do a download and install missing Python packages and then execute:
sudo dpkg --configure -a
...
0
votes
1
answer
2k
views
Path of a file in the user directory from root directory [closed]
Following is the directory structure for a text file textfile.txt ,what will be the file path for the text file for an python script readtext.py which is in the in the root direcory. The python file ...
0
votes
1
answer
3k
views
Where does print statements logged when the python code is started during the bootup
I wrote a .service(systemd) to start a python script during the boot up. There service is working fine and is trying to execute the python script. In order to debug python script i placed few print ...
1
vote
1
answer
615
views
How to install pythoncard?
I am currently running ubuntu 13.10.I want to download pythoncard for python2.7.6.I also have anaconda1.8.0.So whenever i start python in my terminator or terminal,it starts along with anaconda.
0
votes
1
answer
6k
views
Problem while installing random in Python [closed]
I am using python 2.7.4 and having a problem while running pip install random. It comes up with this error:
Collecting random
Could not find a version that satisfies the requirement random (from ...
0
votes
1
answer
3k
views
Cannot install Django using pip
I'm trying to install Django 1.11 on ubuntu 16.04 using pip (python 2.7)
I ran the following command: sudo pip install Django
but I get:
Could not find a version that satisfies the requirement ...
13
votes
1
answer
23k
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
1
answer
908
views
How to detect Linux machine power off state using Python
Below is the code I got from this website to detect resume,
import dbus # for dbus communication (obviously)
import gobject # main loop
from dbus.mainloop.glib import DBusGMainLoop #
...
18
votes
6
answers
51k
views
pip won't run. throws errors instead
I am running into problems when ever I run pip with any arguments or flags. I've tried doing apt-get install --reinstall python-pip but it does not help and am at a loss how to fix this
Version of ...
7
votes
7
answers
32k
views
Eclipse not showing Pydev in Preferences
After installing Eclipse and python I am not able to see Pydev on eclipse. When I try to install eclipse again it is showing as duplicate location.
-2
votes
1
answer
15k
views
OSError: [Errno 2] No such file or directory on Ubuntu 16.04
Using Ubuntu, am trying to use the scikit-learn examples with this snippet:
#!/usr/bin/env python
# -*- coding: utf-8 -*-
""" Examples of reading texts files and classifying them
"""
from __future__ ...
2
votes
1
answer
2k
views
How to install swi-prolog as a shared library?
I need to develop an expert system using prolog as an inference engine and python as interface. I already have the SWI-prolog installed in my machine, but, i can't import the interface PySwip because ...
1
vote
0
answers
1k
views
How to force bash terminal to run Enter after recieving command via python os.system()?
I am running some bash commands via python os.system('/vt -start ./home/mydb ./home/images/image-001-053.png 2>&1 | tee ./ results.txt >/dev/pts/2').
This is a command which can be run on ...
1
vote
1
answer
2k
views
Is it possible to run/execute a bash script command from inside a python code?
I am not an expert, so I am asking my question here. I have C++ code which is using openCV modules. I need this program to send an image (img1.png) from a python code to be processed by this C++ code. ...
0
votes
2
answers
5k
views
Python's ImportError: No module named repository
I had three versions of Python installed; 2.7, 3.2 and 3.4 When I had just 2.7 and 3.2, everything was fine. But after installing 3.4 manually from source, things began to break down. 3.4 did not have ...
0
votes
0
answers
352
views
Errors were encountered while processing: python-minimal
I am continuously getting this error
Errors were encountered while processing:
python-minimal
after I try to install anything through sudo apt-get install ....Initially, my enable wifi option ...
2
votes
3
answers
2k
views
libreoffice Python Uno support for Python 2.7 on Ubuntu Saucy 13.10
I recently upgraded to Ubuntu 13.10 and discovered that the python-uno package is no longer available. Instead I find a python3-uno package. Unfortunately I need Python uno libreoffice support for ...