2016-10-14, 08:44
Thanks a lot for the quick response, I will try this.
Update: this worked. Thanks a lot.
Update: this worked. Thanks a lot.
(2020-10-07, 21:34)serwin Wrote: HelloYour answer is 2 posts back (at the end of the first page).
I have the same issue. I have a hbogo addon, which rejects my credentials, but I can use it on my PC, or TV set.
Trying to analyse the response, but when I try to import the requests library (same as the xbmc etc) the python ide it gives an error:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named requests
this import is in the addon.py and gives no error...
Can you give me some hints to make libraries importable?
Thank you
Ervin
(2016-10-14, 08:23)marian.pavel Wrote: I added <import addon="script.module.requests" version="2.9.1"/> in my addon.xml file
You can view my project here: https://github.com/marianpavel/plugin.vi...rageplayer
(2020-10-08, 20:28)serwin Wrote:Ah, I see. This isn't really the place for general Python script support, but you need to install the requests module using something like pip (which is generally, but not always bundled with the Python distribution for your OS).(2016-10-14, 08:23)marian.pavel Wrote: I added <import addon="script.module.requests" version="2.9.1"/> in my addon.xml file
You can view my project here: https://github.com/marianpavel/plugin.vi...rageplayer
I saw your post, but I trying to use the requests library from a python script, not in an addon, so I have no addon.xml, just typed it to the python prompt (>>> import requests) and got the message.
(2020-10-08, 21:49)pkscout Wrote:(2020-10-08, 20:28)serwin Wrote:Ah, I see. This isn't really the place for general Python script support, but you need to install the requests module using something like pip (which is generally, but not always bundled with the Python distribution for your OS).(2016-10-14, 08:23)marian.pavel Wrote: I added <import addon="script.module.requests" version="2.9.1"/> in my addon.xml file
You can view my project here: https://github.com/marianpavel/plugin.vi...rageplayer
I saw your post, but I trying to use the requests library from a python script, not in an addon, so I have no addon.xml, just typed it to the python prompt (>>> import requests) and got the message.
(2020-10-12, 20:45)serwin Wrote:(2020-10-08, 21:49)pkscout Wrote:(2020-10-08, 20:28)serwin Wrote: I saw your post, but I trying to use the requests library from a python script, not in an addon, so I have no addon.xml, just typed it to the python prompt (>>> import requests) and got the message.Ah, I see. This isn't really the place for general Python script support, but you need to install the requests module using something like pip (which is generally, but not always bundled with the Python distribution for your OS).
Thank you.
Unfortunately, on LibreElec I found no way to install any libraries, pip is not available.
(2020-10-13, 22:40)pkscout Wrote:I see...I just like to debug the HBO GO addon for kodi, trying to test the way it logs in. Probably HBO changed the urls because my requests (copied from the addon source, but used urllib.requests instead of urllib2) got no answer.(2020-10-12, 20:45)serwin Wrote:(2020-10-08, 21:49)pkscout Wrote: Ah, I see. This isn't really the place for general Python script support, but you need to install the requests module using something like pip (which is generally, but not always bundled with the Python distribution for your OS).
Thank you.
Unfortunately, on LibreElec I found no way to install any libraries, pip is not available.
Looks like you can't. LibreElec is just enough OS to get Kodi going. It's apparently not designed for you to do other stuff with it. If you want to run scripts outside Kodi, you'll probably have to switch to some other distro that works with your hardware.