fHDHR / fHDHR_plugin_origin_plutotv

Do What The F*ck You Want To Public License
3 stars 3 forks source link

No program information in xmltv file #2

Closed tharris9d closed 3 years ago

tharris9d commented 3 years ago

@deathbybandaid I've been Plex testing running for a few days now with fHDHR_PlutoTV. If I use the xmltv file from127.0.0.1:5009/xmltv.xml (fHDHR_PlutoTV) in Plex we are losing the program information for the channels.
I deleted the cache, deleted the DVR in Plex. Stopped the Plex server. I then added it in again. Still no program info on the Pluto Channels. When I first installed it we got all the info. I am wondering if something changed in the api?


UPDATE! I was able to get 127.0.0.1:5009/xmltv.xml to refresh with Program Information by restarting Plex Server, deleting the fHDHR_PlutoTV cache, and then stopping fHDHR_PlutoTV and restarting it again.

deathbybandaid commented 3 years ago

Good!

deathbybandaid commented 3 years ago

Looks like their API has changed for me now,, looking at this now

deathbybandaid commented 3 years ago

fixed

crackers8199 commented 3 years ago

is this broken again? when i try to click on the guide or xmltv, i get a 500 error...

deathbybandaid commented 3 years ago

You using the most recent push?

deathbybandaid commented 3 years ago

My guide seems to load without issue

image

crackers8199 commented 3 years ago

You using the most recent push?

yup. literally just cloned it about 20 minutes ago.

deathbybandaid commented 3 years ago

I'll clear my cache and update, but I bet it works

crackers8199 commented 3 years ago
fHDHR - INFO - Updating plutotv EPG cache.
fHDHR - INFO - FROM CACHE:  1605225600.0
fHDHR - INFO - FROM CACHE:  1605254400.0
fHDHR - INFO - FROM CACHE:  1605283200.0
fHDHR - INFO - FROM CACHE:  1605312000.0
fHDHR - INFO - FROM CACHE:  1605340800.0
fHDHR - INFO - FROM CACHE:  1605369600.0
fHDHR - INFO - FROM CACHE:  1605398400.0
fHDHR - INFO - FROM CACHE:  1605427200.0
fHDHR - INFO - FROM CACHE:  1605456000.0
fHDHR - INFO - FROM CACHE:  1605484800.0
fHDHR - INFO - FROM CACHE:  1605513600.0
fHDHR - INFO - FROM CACHE:  1605542400.0
fHDHR - INFO - FROM CACHE:  1605571200.0
fHDHR - INFO - FROM CACHE:  1605600000.0
fHDHR - INFO - FROM CACHE:  1605628800.0
fHDHR - INFO - FROM CACHE:  1605657600.0
fHDHR - INFO - FROM CACHE:  1605686400.0
fHDHR - INFO - FROM CACHE:  1605715200.0
fHDHR - INFO - FROM CACHE:  1605744000.0
fHDHR - ERROR - Exception on /guide [GET]
Traceback (most recent call last):
  File "/home/crackers8199/.local/lib/python3.6/site-packages/flask/app.py", line 2447, in wsgi_app
    response = self.full_dispatch_request()
  File "/home/crackers8199/.local/lib/python3.6/site-packages/flask/app.py", line 1952, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/home/crackers8199/.local/lib/python3.6/site-packages/flask/app.py", line 1821, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/home/crackers8199/.local/lib/python3.6/site-packages/flask/_compat.py", line 39, in reraise
    raise value
  File "/home/crackers8199/.local/lib/python3.6/site-packages/flask/app.py", line 1950, in full_dispatch_request
    rv = self.dispatch_request()
  File "/home/crackers8199/.local/lib/python3.6/site-packages/flask/app.py", line 1936, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/home/crackers8199/fhdhr/fHDHR_PlutoTV/fHDHR/http/pages/guide_html.py", line 17, in __call__
    return self.get(*args)
  File "/home/crackers8199/fhdhr/fHDHR_PlutoTV/fHDHR/http/pages/guide_html.py", line 46, in get
    for channel in self.fhdhr.device.epg.whats_on_allchans():
  File "/home/crackers8199/fhdhr/fHDHR_PlutoTV/fHDHR/device/epg.py", line 78, in whats_on_allchans
    whatson = self.whats_on_now(channel["number"])
  File "/home/crackers8199/fhdhr/fHDHR_PlutoTV/fHDHR/device/epg.py", line 63, in whats_on_now
    epgdict = self.get_epg()
  File "/home/crackers8199/fhdhr/fHDHR_PlutoTV/fHDHR/device/epg.py", line 95, in get_epg
    self.update(method)
  File "/home/crackers8199/fhdhr/fHDHR_PlutoTV/fHDHR/device/epg.py", line 146, in update
    programguide = func_to_call(self.channels)
  File "/home/crackers8199/fhdhr/fHDHR_PlutoTV/fHDHR/origin/__init__.py", line 61, in update_epg
    return self.epg.update_epg(channels)
  File "/home/crackers8199/fhdhr/fHDHR_PlutoTV/fHDHR/origin/origin_epg.py", line 91, in update_epg
    "time_start": self.xmltimestamp_pluto(progdict["start"]),
  File "/home/crackers8199/fhdhr/fHDHR_PlutoTV/fHDHR/origin/origin_epg.py", line 16, in xmltimestamp_pluto
    xmltime = datetime.datetime.fromisoformat(xmltime)
AttributeError: type object 'datetime.datetime' has no attribute 'fromisoformat'
192.168.88.70 - - [2020-11-13 20:36:36] "GET /guide HTTP/1.1" 500 426 2.075505
deathbybandaid commented 3 years ago

well that's interesting

deathbybandaid commented 3 years ago

I do all my testing on Ubuntu, py3.8

Not able to reproduce that issue

deathbybandaid commented 3 years ago

Looks like it's new as of python 3.7

crackers8199 commented 3 years ago

docker container no longer builds either since the addition of pycrypto as a requirement, i wonder if that has something to do with this. i'll have to dig further to figure out what's going on there.

deathbybandaid commented 3 years ago

PlutoTV especially needs the pycrypto, as the chunks have to be decrypted after download for the direct streaming of their m3u8 playlist

deathbybandaid commented 3 years ago

If you want the reigns on docker support, that would give you PRs for all of the fHDHR repos

crackers8199 commented 3 years ago

figured out the issue with the docker container, and i can't reproduce the error in there. i'm guessing it had something to do with the fact the computer i ran it on had py3.6 and the image uses 3.8. i'll get a PR up in a sec.

deathbybandaid commented 3 years ago

make sure you PR all the repos! please

crackers8199 commented 3 years ago

@deathbybandaid done

deathbybandaid commented 3 years ago

sweet, going to re-close this issue!