chkuendig / tvhProxy

📡 Connect Plex DVR with tvheadend (incl. EPG)
https://christian.kuendig.info/posts/2020-02-tvhproxy/
Other
43 stars 9 forks source link

JSONDecodeError: Lineup.json #7

Closed KorewaKiyo closed 3 years ago

KorewaKiyo commented 3 years ago

Similar to #1

I'm having the lineup json error.

ERROR:tvhProxy:Exception on /lineup.json [GET]
Traceback (most recent call last):
  File "/home/pi/tvhProxy/.venv/lib/python3.7/site-packages/flask/app.py", line 2447, in wsgi_app
    response = self.full_dispatch_request()
  File "/home/pi/tvhProxy/.venv/lib/python3.7/site-packages/flask/app.py", line 1952, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/home/pi/tvhProxy/.venv/lib/python3.7/site-packages/flask/app.py", line 1821, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/home/pi/tvhProxy/.venv/lib/python3.7/site-packages/flask/_compat.py", line 39, in reraise
    raise value
  File "/home/pi/tvhProxy/.venv/lib/python3.7/site-packages/flask/app.py", line 1950, in full_dispatch_request
    rv = self.dispatch_request()
  File "/home/pi/tvhProxy/.venv/lib/python3.7/site-packages/flask/app.py", line 1936, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "tvhProxy.py", line 82, in lineup
    for c in _get_channels():
TypeError: 'NoneType' object is not iterable
INFO:root:::ffff:192.168.0.1 - - [2021-04-16 01:35:09] "GET /lineup.json HTTP/1.1" 500 426 0.034379

I've tried disabling and enabling digest auth, to no effect, the only thing that makes it work is disabling acls in tvheadend with --noacl but that's not ideal

KorewaKiyo commented 3 years ago

Also seems like tvhProxy.env isn't working? I have TVH_URL set but lineup.json still returns localhost:9981 image image

chkuendig commented 3 years ago

Did you make sure to rename the file to .env? I have switched to docker and don't use the .env file anymore for my configuration, so I'm not able to test this currently.

KorewaKiyo commented 3 years ago

Sorry, completely forgot about opening this issue, it was due to ACLs, running tvh with -noacl seemed to fix the issue, so I'm using it that way for now.

I was gonna look into fixing the issue but completely forgot haha