Opened 11 years ago

Closed 11 years ago

#4725 closed defect (fixed)

Scheduler not properly coordinating its schedule with LiveTV.

Reported by: Ron Frazier <ron@…> Owned by: bjm
Priority: minor Milestone: 0.21
Component: scheduler Version: 0.21-fixes
Severity: medium Keywords:
Cc: danielk@… Ticket locked: no

Description

The scheduler doesn't appear to coordinate it's recording effort correctly with LiveTV. As a result it missed recording part of a program that had no later showings in favor of another program that had multiple later showings with no conflicts. I was able to recreate this by doing the following. Note...my system has 2 HD tuners of higher priority and then 3 SD tuners of lower priority.

I scheduled 3 programs to record, all with the "Record at any time on channel X" option (all 3 programs are on different channels). The following conflict ocurred:

Program 1 (Montel Williams) was scheduled to record from 12PM to 1PM on tuner 1 and had no later showings.
Program 2 (Jeopardy!) was scheduled to record from 12:30PM to 1PM on tuner 2 and had no later showings.
Program 3 (Painting With Paulson) was NOT scheduled to record from 12:30PM to 1PM because it had a later showing available.

Here is the relevant output from mythbackend --printsched

Title - Subtitle                Ch Station Day Start  End   S C I  T N   Pri
Montel Williams                 202 WJBK    20 12:00-13:00  2 1 1  C 1   5/0
Jeopardy!                       203 WDIV    20 12:30-13:00  2 2 2  C 2   5/0
Painting With Paulson - "The S  205 PBSHD   20 12:30-13:00  2 0 0  C L   5/0
.....
Painting With Paulson - "The S  205 PBSHD   21 10:00-10:30  2 1 1  C 1   5/0

Next, start LiveTV on tuner 1 and tune it to channel 202 sometime prior to the beginning of the 12PM recording. This is the channel that Program 1 (Montel Williams) is scheduled to record on. I'm not sure if tuning to the specific channel is necessary to demonstrate the bug, but it's what happened in my case. The TV was turned off while still watching LiveTV on that channel several hours prior.

When 12PM rolls around, instead of recording Program 1 it continues on and shows Program 1 as LiveTV. When myth then reruns the scheduler before 12:30PM, it comes up with a new schedule:

Title - Subtitle                Ch Station Day Start  End   S C I  T N   Pri
Jeopardy!                       203 WDIV    20 12:30-13:00  2 1 1  C 1   5/0
Painting With Paulson - "The S  205 PBSHD   20 12:30-13:00  2 2 2  C 2   5/0

Program 2 (Jeopardy!) got bumped up from tuner 2 to tuner 1, and Program 3 (Painting With Paulson) got bumped up from a later showing to the earlier showing on tuner 2. When 12:30PM rolls around, myth then decides to interrupt LiveTV to record both of those scheduled programs. As a rusult, Program 1 only has 1/2 of the recording in the LiveTV storage group and no opportunty to rerecord the whole thing at a later time.

I believe the ideal way to handle it would have been for the scheduler to realize it should treat Program 1 as a recording rather than LiveTV and to keep Program 3 at the later showing time.

Change History (5)

comment:1 Changed 11 years ago by bjm

Milestone: unknown0.21
Status: newaccepted
Version: head0.21-fixes

This appears to be an obvious a bug and I agree with your conclusion. If "Montel Williams" had been marked as a recording in progress as it should have, the others would not have interfered.

BTW Thank you for the detailed test case. Demonstrating how to reproduce the behavior is much more valuable than any other description. I have several questions but I can test on my own.

In a simpler test, I set a Single rule for the next half hour then went to live TV for that channel on the assigned input. There was no popup in the last minute and live TV continued into the target show. After exiting live TV, the schedule showed that target show was marked "L" which should be impossible for a kSingleRecord.

comment:2 Changed 11 years ago by danielk

Cc: danielk@… added

bjm, let me know if this is a problem with the LiveTV popup itself. I made some major changes there for multirec.

comment:3 in reply to:  1 Changed 11 years ago by Ron Frazier <ron@…>

Replying to bjm:

BTW Thank you for the detailed test case.

No problem. I'm a programmer, so I understand how it helps.

In a simpler test, I set a Single rule for the next half hour then went to live TV for that channel on the assigned input. There was no popup in the last minute and live TV continued into the target show. After exiting live TV, the schedule showed that target show was marked "L" which should be impossible for a kSingleRecord.

Then it looks like the scheduler's lack of cooperation with LiveTV may be a more general problem. You just reminded me that I submitted another bug report a while back where watching LiveTV prevents scheduling a recording in progress. Ticket #4437. The solution to both bugs might be the same.

comment:4 Changed 11 years ago by bjm

Daniel, I believe that LiveTVPriority and friends are yielding the scheduled show incorrectly (thus the "L" for a single) and therefore the popup is never called for. However, I will bang on the popup options before the release now that you mention it.

comment:5 Changed 11 years ago by bjm

Resolution: fixed
Status: acceptedclosed

(In [16182]) Fixes a bug introduced in [15528] where the move_this flag was not checked during conflict resolution. This caused confusion where live TV was running when a scheduled recording should begin. This specific fix was suggested by Shane.

This should close #4725 and address a discussion on the mailing list about scheduling a Single in progress from live TV then seeing it marked as "L"ater Showing.

Note: See TracTickets for help on using tickets.