"Auto" recording timers sometimes not shutting down

Issue #588 resolved
prl created an issue

On a T4 or T3, if there's no Internet available at startup, at the time when it's being checked whether the startup is for a recording timer with "auto" set for its "After event" action, the correct system time is not set, and so the test for that condition fails.

That then means that the system will not go to standby to complete the recording, and at the end of the recording, the system will not shut down.

If there is a valid broadcast service set for startup, the time will be set about 10 sec after the test for the "auto" timer.

The test that fails when it should succeed is in Navigation.__init__():

        if getFPWasTimerWakeup():
            self.__wasTimerWakeup = True
            if nextRecordTimerAfterEventActionAuto and abs(self.RecordTimer.getNextRecordingTime() - time()) <= 360:  # <<< This test fails because the system time has not been set yet
                print '[Navigation] RECTIMER: wakeup to standby detected.'

The problem occurs whether MENU>Setup>System>Time settings>Sync time is set to "TV broadcast" or "NTP (Internet)".

The T2 is not affected by this problem because it's not capable of distinguishing a timer startup from manual startup.

Workaround is to ensure that an Internet connection is always available at startup.

Replication steps

Do this this with MENU>Setup>System>Time settings>Sync time using set to both "TV broacast" and "NTP (Internet)".

Set a recording timer in the near future with its "After event" action set to "auto".

Leave a TV on and connected to observe system behaviour.

Shutdown the system, disconnect its Ethernet cable and wait for the timer to start.

The system starts normally, and goes to fully running. However, it does not go to standby 15 sec after the above test as intended.

When the recording finishes, the system does not return to shutdown, but continues in live TV.

Comments (2)

  1. Peter Urbanec

    Fix Bug #588: "Auto" recording timers sometimes not shutting down

    Detect that the system time has not been correctly set when Navigation.init() is called, and if the time has not been set correctly, arrange for the code that should be run on a timer wakeup to be re-run after the system clock has been set.

    → <<cset 1126c874ea8a>>

  2. Log in to comment