Closed JanCeuleers closed 2 years ago
Sorry, it seems that the attachment links are interspersed with the text above, and I can't seem to fix it.
The tv_grab_nl3_py.conf.log I attached earlier was for a run that I cut short, so here is one for a run that lasted 5+ hours. tv_grab_nl3_py.conf_log2.txt
Sorry it took some time. I think I know why the disable_source statement gives an error. If I'm right, adding one of the two on the command-line will disable both sources without any error. I think I forgot an initialization statement. :-(
Try disabling source 1 (tvgids.tv) on the command-line because that's the one giving problems. For me it has been failing altogether for some time. Just like primo and rtl.
I'll delve further into those sources.
I got somewhat wiser. My colleague already disabled source 1 on the 15th and it is playing up as detailsource. The error should now be gone. As to your error on disabling sources in your config, I don't get them. I even ran with your config file. So can you add a traceback to the relevant log entry? and give your log file here? line 1636 in tv_grab_config.py:
- self.log([self.text('config', 37, (self.opt_dict['config_file'],)),'%r\n' % (line)])
+ self.log([self.text('config', 37, (self.opt_dict['config_file'],)),'%r\n' % (line), traceback.format_exc()])
Thank you very much for your time. I confirm that the grabber now works for me.
Will report back with the requested traceback.
First a question though: how do I find out which instance of the tv_grab_config.py file is actually being used?
root@dracor:~# locate tv_grab_config.py /home/mythtv/tmp/tvgrabpyAPI-stable-1.0.9/build/lib.linux-x86_64-2.7/tvgrabpyAPI/tv_grab_config.py /home/mythtv/tmp/tvgrabpyAPI-stable-1.0.9/tvgrabpyAPI/tv_grab_config.py /home/mythtv/tmp/tvgrabpyAPI-stable-1.0.9/tvgrabpyAPI/tv_grab_config.pyc /home/mythtv/tvgrabpyAPI/tvgrabpyAPI-master/build/lib.linux-x86_64-2.7/tvgrabpyAPI/tv_grab_config.py /home/mythtv/tvgrabpyAPI/tvgrabpyAPI-master/tvgrabpyAPI/tv_grab_config.py /home/mythtv/tvgrabpyAPI/tvgrabpyAPI-master/tvgrabpyAPI/tv_grab_config.pyc /home/mythtv.zotac/tvgrabpyAPI/tvgrabpyAPI-master/tvgrabpyAPI/tv_grab_config.py /install.home/mythtv/tvgrabpyAPI/tvgrabpyAPI-master/build/lib.linux-x86_64-2.7/tvgrabpyAPI/tv_grab_config.py /install.home/mythtv/tvgrabpyAPI/tvgrabpyAPI-master/tvgrabpyAPI/tv_grab_config.py /install.home/mythtv/tvgrabpyAPI/tvgrabpyAPI-master/tvgrabpyAPI/tv_grab_config.pyc /root/tmp/tvgrabpyAPI-stable-1.0.8/build/lib.linux-x86_64-2.7/tvgrabpyAPI/tv_grab_config.py /root/tmp/tvgrabpyAPI-stable-1.0.8/tvgrabpyAPI/tv_grab_config.py /root/tmp/tvgrabpyAPI-stable-1.0.8/tvgrabpyAPI/tv_grab_config.pyc /usr/local/lib/python2.7/dist-packages/tvgrabpyAPI/tv_grab_config.py /usr/local/lib/python2.7/dist-packages/tvgrabpyAPI/tv_grab_config.pyc
Good, that it works.
I guess /usr/local/lib/python2.7/dist-packages/tvgrabpyAPI/tv_grab_config.py
This is where it's installed and is also the location mentioned in your error message. The frontend tv_grab_nl3.py
can be placed anywhere, but the dist-packages
directory is where python looks for all added libraries. The .pyc
files are a kind of more python friendly pre-processed versions. They get recreated automatically on any change to the .py
file.
I already got some confirmation through the source testing frontend, but that uses only a subset of the normal frontend. The weird thing is that I there do not get the error. It seems I programmed a bit lazy by using part of the commandline processing structure in processing this config parameter.
In my copy of that file the line in question occurs at line number 1629 rather than 1636.
Log of a patched run: tv_grab_nl3_py_conf_log.txt
The command line was
/usr/local/bin/tv_grab_nl3.py --disable-source 6 --disable-source 7 --disable-source 1 --config-file tv_grab_nl3_py.conf --output tv_grab_nl3_py.out
Thanks! It's not what I thought. It's a bug fixed in 1.0.10 and you're still running 1.0.9. ;-)
Here you find the latest. https://github.com/tvgrabbers/tvgrabpyAPI/releases/tag/stable-1.0.10
Since a few days tv_grab_nl3.py no longer finishes (but keeps hogging one core). Shortly after it starts the following error message is displayed:
mythtv@dracor:~/.xmltv$ /usr/local/bin/tv_grab_nl3.py --config-file tv_grab_nl3_py.conf --output tv_grab_nl3_py.out Loaded the English texts file Using config file: tv_grab_nl3_py.conf Error while reading a line in the [Configuration] section of config file tv_grab_nl3_py.conf:u'disable_source = 7' Error while reading a line in the [Configuration] section of config file tv_grab_nl3_py.conf:u'disable_source = 6' Downloading tv_grab_API.json... Downloading tv_grab_nl.json... Exception in thread source-tvgids.tv: Traceback (most recent call last): File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner self.run() File "/usr/local/lib/python2.7/dist-packages/tvgrabpyAPI/tv_grab_fetch.py", line 2037, in run detail_idx = self.config.detail_sources.index(self.proc_id) ValueError: 1 is not in list
Start time of this run: 2021-12-19 07:26 Verifying the database
(etc.) It then proceeeds to do a lot of work, which eventually stalls (no further screen output) but several hours later still consumes one CPU core, until killed. tv_grab_nl3_py_conf_log.txt
(Note that the above also shows another problem, namely that the disable_source statements include tv_grab_nl3_py_conf.txt d in the configuration file by --configure are not understood by the grabber on subsequent runs; excluding a source only works if this done through the command line).
mythtv@dracor:~/.xmltv$ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 20.04.3 LTS Release: 20.04 Codename: focal
mythtv@dracor:~/.xmltv$ python2 --version Python 2.7.18