[mythtv-users] Can't seem to delete channels

faginbagin helen.buus at gmail.com
Sun Aug 1 18:32:01 UTC 2021


On 7/31/2021 11:38 PM, f-myth-users at media.mit.edu wrote:
> I think you're basically correct.  Having now looked at this more
> carefully, it appears two things are true:
>
> (a) Deselecting a channel in the sqlite DB -does- in fact stop it being
> downloaded by tv_grab_zz_sdjson_sqlite---those channels are now showing
> "NO DATA" out past a certain horizon in the mythweb listings page,
> whereas others are showing data, and looking at the raw XML data
> downloaded (snatched from /tmp during a grabber run) shows that the ones
> I deselected are missing from the <channel> ... </channel> block at the
> beginning but were present in the one I saved from my very first run. [1]
>
> However, deselection may actually be a bad idea---the "CHANNEL SELECTION"
> section of the tv_grab_zz_sdjson_sqlite manpage seems to be one large
> caveat about how confusion between "channel" and "station" might cause
> the wrong thing to happen if the provider starts rearranging things.
>
> So maybe I'll leave everything selected and just set channels invisible
> on the mysql side, though that involves downloading about twice as much
> data and twice as much mfdb work to do for a bunch of channels which are
> marked invisible and hence will never be scheduled.
>
> (b) There's no communications channel from the grabber to myth to tell
> myth that a channel has been deselected.  However, setting it invisible
> (not, as I started out in my Subject: line, trying to delete it, as the
> Channel Editor [2] does) does in fact do the right thing, and that's how
> I did it in my ancient installation---invisibility dropped it from both
> scheduling and display.  So I'll probably just do that via direct DB
> manipulation or perhaps an API call---I did before & after mysql DB
> dumps after setting a channel invisible, and it clearly only modified
> its visibility in the channel table.  (We're talking hundreds of
> channels here, so there's no way I'm going to be doing this by hand.)
>
> [1] I wish there was some easy way to tell tv_grab_zz_sdjson_sqlite to
> preserve the original file.  I suspect I could use one of the debugging
> flags to download it a second time into a file and leave the file alone,
> but that's pretty inefficient, and racy too.  Or I can make something
> that watches for the file to appear in /tmp and copies it once it hasn't
> changed for a little while and/or ends in "</tv>", since it doesn't get
> deleted for many minutes while mfdb runs. :)  If there's a straightforward
> way to do this, I can't find it in the manpage.
Why copy when you can save the file using a hard link, e.g. "ln" without 
the "-s"? You can do that the moment tv_grab... creates the file and the 
hard linked version will still be there even after tv_grab or mfdb 
deletes the original file.
> [2] It is super-confusing that there are -three- "channel editors"---
> the wiki mentions a perl script, the frontend, and mythtv-setup.
> The one I've been talking about is the latter.
>



More information about the mythtv-users mailing list