Odd FAV behaviour after zap timer changes bouquet

Issue #476 resolved
prl created an issue

This problem was touched on in the replication steps in Bug #475, but is not directly caused by Bug #475. Fixing it is necessary for the fix to Bug #475 to work.

When a zap timer starts, the current bouquet is set to the first bouquet in the bouquet list (FAV, BLUE Favourites from live TV) that contains the channel being zapped to.

However, the first time FAV is pressed after the zap timer starts shows the original bouquet (the one that was current before the timer start), and the correct new bouquet is only then shown after a further EXIT, FAV.

The fix for this (preventing ChannelSelection.instance from being initialised by both ChannelSelection.__init__() and PiPZapSelection.__init__()) requires changes in InfoBarChannelSelection.zapUp() and InfoBarChannelSelection.zapDown() because they depend on ChannelSelection.instance being initialised to the incorrect value (the instance of PiPZapSelection).

Replication steps

This assumes that Bug #475 has not been fixed. It also assumes that the first two entries in the bouquet list are Terrestrial TV LCN and Last Scanned, in that order, and (apart from HDMI IN on a T4), they have the same set of channels.

Set the current bouquet to Last Scanned.

Set a zap timer for a short time ahead on any channel in Last Scanned that is also in Terrestrial TV LCN.

Wait for the zap timer to start.

Press FAV and the current bouquet will still be shown as Last Scanned.

Press EXIT, FAV, and the current bouquet will change to Terrestrial TV LCN and remain there for subsequent uses of FAV, unless changed by the user. It is this last behaviour that is the subject of this bug.

Comments (3)

  1. Peter Urbanec

    Fix #476: Odd FAV behaviour after zap timer changes bouquet

    [ChannelSelection]

    Ensure that ChannelSelection.instance is initialised only when a ChannelSelection object is initialised, and not when a derived object is created (like a PiPZapSelection).

    Correct the assert text to refer to ChannelSelection, not InfoBar.

    [InfoBarChannelSelection]

    Remove the unnecessary use of ChannelSelection.instance in zapUp() and zapDown() and replace it with self.servicelist2.

    The original code depended on ChannelSelection.instance being incorrectly initialised to the single system instance of PiPZapSelection (which is also referenced by self.servicelist2).

    → <<cset bc4599cd1a44>>

  2. Log in to comment