Recording OTA program gives me 2 recordings?

Have a MythTV related problem? Ask for help from other MythTV users here.

Moderator: Forum Moderators

Post Reply
flabbergast
Newcomer
Posts: 11
Joined: Sun May 31, 2015 4:26 pm
United States of America

Recording OTA program gives me 2 recordings?

Post by flabbergast »

Using Mythtv 31.0 in Kubuntu 21.04. When I record a program I often get a double recording of the same channel. One will start recording about 30 to 60 seconds after the first. Is this a known problem? I can just delete one but it is annoying.
ulmus-scott
Junior
Posts: 41
Joined: Sat Jun 05, 2021 12:50 am
United States of America

Re: Recording OTA program gives me 2 recordings?

Post by ulmus-scott »

I have had this happen only once. Yesterday, actually. Xubuntu 21.04 with mythbuntu ppa

From my post about title issues with manual recordings: viewtopic.php?f=36&t=4560
In an unusual case, it duplicated a recording, but the duplicated recording ("Liza with a Z") started one minute later than the manually scheduled "Liza with a Z (Manual Record)". (Both recordings included the entire show because we record 2 minutes before and after every show, i.e. the duplicate only recorded one minute before the show.)
User avatar
heyted
Senior
Posts: 301
Joined: Sun Jun 08, 2014 2:14 am
Location: South Florida
Contact:
United States of America

Re: Recording OTA program gives me 2 recordings?

Post by heyted »

I'm using MythTV v31 from the Mythbuntu PPA on Ubuntu 20.04, and I'm not seeing any duplicate recordings.
Ted | My blog
User avatar
kmdewaal
Developer
Posts: 644
Joined: Wed Dec 07, 2016 8:01 pm
Netherlands

Re: Recording OTA program gives me 2 recordings?

Post by kmdewaal »

A duplicate recording can happen with the following sequence:
- a recording is scheduled to start recording a few minutes before the start of the program
- after the start of the recording but before the start of the program the start time of the program is changed by EIT
- then a second recording is started because a new start time is seen as a new program
This happens to me sometimes on sports channels where live events often cause last-minute schedule changes.
Note that recordings that are already started always continue to the end even if the guide data disappears halfway.
ulmus-scott
Junior
Posts: 41
Joined: Sat Jun 05, 2021 12:50 am
United States of America

Re: Recording OTA program gives me 2 recordings?

Post by ulmus-scott »

kmdewaal wrote: A duplicate recording can happen with the following sequence:
- a recording is scheduled to start recording a few minutes before the start of the program
- after the start of the recording but before the start of the program the start time of the program is changed by EIT
- then a second recording is started because a new start time is seen as a new program
This happens to me sometimes on sports channels where live events often cause last-minute schedule changes.
So you're saying this is a known quirk/bug in the scheduler. Presumably because it does not compare the channel, start time, and end time to determine that it is already being recorded, right?

What would be the desired behavior? To delay the existing recording's end time, if necessary, to encompass both the already started recording's end time and the end time from the new guide data? This would also mark the would be duplicate recording as recorded under an earlier showing.

If it is difficult to modify an ongoing recording's end time, a duplicate recording including the extra time after the initial recording may be an acceptable, easier solution.
kmdewaal wrote: Note that recordings that are already started always continue to the end even if the guide data disappears halfway.
I assume this is because the scheduler can only start recordings, not end them, or modify ongoing recordings.

Do you think this is related to my issue with the titles of manual recordings?
User avatar
kmdewaal
Developer
Posts: 644
Joined: Wed Dec 07, 2016 8:01 pm
Netherlands

Re: Recording OTA program gives me 2 recordings?

Post by kmdewaal »

The EIT updates the guide but it does not know anything about recordings. Program start time is updated when the start time is in the future. Program end time is updated when the end time is in the future. This does not take the extra minutes of recording before and after the program into account. And the scheduler looks at the guide and sees a new program if the start time is even one minute earlier or later.
Note that with multirec the additional recording will be made from the same real tuner so it does not use another real tuner.
A possible solution is to take the pre-roll time into account in the EIT code and only change the start time when the current time is before the start time plus the pre-roll time. Another possible solution is to check if the program is actually being recorded but that is not trivial and it adds coupling between the EIT and the scheduler.
Do you think this is related to my issue with the titles of manual recordings?
The EIT updates the guide based on the principle of ¨newer is better" so a program title received via EIT will be used to update the guide.
Program matching is done on start time and title (among others) so that sounds like a possible path. However, I do not think that manual recordings are entered into the program guide, but it is a few years since I updated the EIT code....
ulmus-scott
Junior
Posts: 41
Joined: Sat Jun 05, 2021 12:50 am
United States of America

Re: Recording OTA program gives me 2 recordings?

Post by ulmus-scott »

kmdewaal wrote: The EIT updates the guide but it does not know anything about recordings. Program start time is updated when the start time is in the future. Program end time is updated when the end time is in the future. This does not take the extra minutes of recording before and after the program into account. And the scheduler looks at the guide and sees a new program if the start time is even one minute earlier or later.
Emphasis mine. I don't think the EIT updating is a problem per se. I think the problem is the scheduler blindly adding a new match.

Once the EIT is updated (presumably before the recording starts, but maybe not), the scheduler sees a new match and adds it to the list of upcoming recordings. The scheduler knows what upcoming recordings are planned, including channel, start and end times, pre- and post-roll amount, title, right? With this information the scheduler should be able to determine that it already has scheduled (or started) a recording on that channel at that time (with that title?). Instead of adding a new recording, the scheduler should modify the recording to encompass the earliest (if not already started) and latest times, taking into consideration the pre- and post-roll amounts. Possibly, modifying only the pre- or post-roll amount.
Note that with multirec the additional recording will be made from the same real tuner so it does not use another real tuner.
Yes, but isn't the max number of simultaneous recordings on a digital tuner a fixed integer (default of 2)? In need of updating: https://www.mythtv.org/wiki/Setup_Capture_Cards

I'll reply on my other thread about the titles and manual recordings to not clutter this thread with a potentially different issue.
jtlpa
Newcomer
Posts: 3
Joined: Sat May 24, 2014 3:21 am
United States of America

Re: Recording OTA program gives me 2 recordings?

Post by jtlpa »

Have been using MythTV for the last 9 years and this issue has always been present. It is good see a discussion has been initiated to possibly help resolve the issue.

FYI currently using
Ubuntu-MATE 20.04-3
MythTV fixes/31 (v31.0-31.0)
jtlpa
Newcomer
Posts: 3
Joined: Sat May 24, 2014 3:21 am
United States of America

Re: Recording OTA program gives me 2 recordings?

Post by jtlpa »

Don't know if this info might help the programmers in the forum, but here it is...

Just recorded the move Nevada Smith from CH 28_3 WPGX-GT and ended up with two recordings.
MythTV displays the two recordings from top down as:
1 hour 50 minutes 12:00 PM to 2:00 PM
2 hours 59 minutes 11:00 AM to 2:00 PM
Titan TV shows it as 3 hours long 11:00 AM to 2:00 PM
Both recordings have the same title and description. Recording rule was set to start and end on time on this channel only.
mythallday
Newcomer
Posts: 2
Joined: Mon Oct 17, 2016 2:25 am
Pitcairn Island

Re: Recording OTA program gives me 2 recordings?

Post by mythallday »

I've found duplicates if the default "Record this showing" option is chosen when selecting the program via the EPG.

It's resolved with the recording option, "Only One Showing".

Is there a DB script or menu item change to set "Only One Showing" as the default when selecting items to the record in the EPG?
Post Reply