edit4ever / script.module.zap2epg

zap2epg - EPG grabber for USA/Canada
GNU General Public License v3.0
41 stars 25 forks source link

Detail JSONs don't download #28

Closed msorice closed 3 years ago

msorice commented 3 years ago

Setting xdetails to true results in log output like this:

2020/12/20 21:12:02 Downloading details data for: SH03689230 2020/12/20 21:12:02 Could not parse data for: 1608517800 - deleting file - POST data should be bytes, an iterable of bytes, or a file object. It cannot be of type str. Traceback (most recent call last): File "zap2epg.py", line 537, in parseXdetails JSONcontent = urllib.request.urlopen(URLcontent).read() File "/usr/lib/python3.8/urllib/request.py", line 222, in urlopen return opener.open(url, data, timeout) File "/usr/lib/python3.8/urllib/request.py", line 522, in open req = meth(req) File "/usr/lib/python3.8/urllib/request.py", line 1281, in dorequest raise TypeError(msg) TypeError: POST data should be bytes, an iterable of bytes, or a file object. It cannot be of type str.

msorice commented 3 years ago

I've discovered further that this only occurs in the Python3/v2.0.0 branch of the code. The master/v1.3.1 (python 2) branch code runs fine.