Interpreting Python Error Codes

discuss compiling applications for Puppy
Post Reply
Message
Author
bh56
Posts: 55
Joined: Tue 07 Apr 2009, 08:04

Interpreting Python Error Codes

#1 Post by bh56 »

Hi,
I'm trying to use webdl from https://delx.net.au/projects/webdl.
I've installed livestreamer and its dependencies.
To get the program to run I use python ./grabber from the webgl folder.
I get this output:
Choose> 1
INFO Downloading: Glass A Portrait Of Philip In Twelve Parts.ts
Traceback (most recent call last):
File "/usr/local/bin/livestreamer", line 5, in <module>
from pkg_resources import load_entry_point
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2749, in <module>
working_set = WorkingSet._build_master()
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 444, in _build_master
ws.require(__requires__)
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 725, in require
needed = self.resolve(parse_requirements(requirements))
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 628, in resolve
raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: requests>=1.0,<3.0
ERROR livestreamer exited with error code: 1
Press return to continue...
Could anybody be able to interpret what this all means (and how to fix it)?
Brendan

learnhow2code

Re: Interpreting Python Error Codes

#2 Post by learnhow2code »

the main thing here is:
Traceback (most recent call last):
File "/usr/local/bin/livestreamer", line 5, in <module>
from pkg_resources import load_entry_point


thats the line of python (line 5) in the file "/usr/local/bin/livestreamer" that isnt working.

"most recent call last" if you look at the call at the bottom of the traceback (i think these things are difficult to follow, but they often do a lot to hint at the issue) it says: pkg_resources.DistributionNotFound: requests>=1.0,<3.0

what i know about this is: python requests is a python library. it seems to suggest you need a version of python requests (or even a version of python that includes it) that is between 1.0 and 2.x, but NOT 3.0.

if i do a search for python-requests in apt it gives me:
python-requests - elegant and simple HTTP library for Python2, built for human beings
this means its probably not a standard python library-- its 3rd party. so if i install it, and run dpkg -l | grep requests i get that its version 2.4.3-6 (sound good, lets get you a copy):

go to http://packages.debian.org ... look for python-requests in the search... click on stable...

http://http.us.debian.org/debian/pool/m ... -6_all.deb

save that and dpkg-deb -x python-requests_2.4.3-6_all.deb / ...in puppy.

then run python:
# python

and see if it lets you do this command:
>>> import requests

if it has an error, youre still not set up. let me know what it says.

if it says this as a reply:

>>>

then try to run gstreamer again.

its been a week, so perhaps you gave up. thats understandable. take care.

bh56
Posts: 55
Joined: Tue 07 Apr 2009, 08:04

Error codes

#3 Post by bh56 »

Thanks for your reply.
I've downloaded a number of python modules and got one part of the program to run.
The program I'm running is python ./grabber.
It in turn, is calling another program called livestreamer.
Livestreamer fails with this error

livestreamer is not supposed to be run as root. If you really must you can do it by passing --yes-run-as-root.
ERROR livestreamer exited with error code: 1
Press return to continue...

Strangely running
livestreamer --yes-run-as-root
fails with with an unrecognized argument error.

I think I need to post in the livestreamer forum if there is one.
Thanks again.

Post Reply