Bug 497738 - Incorrect time markers
Summary: Incorrect time markers
Status: RESOLVED FIXED
Alias: None
Product: Telly Skout
Classification: Applications
Component: General (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Unassigned bugs mailing-list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-12-21 04:36 UTC by Ralf
Modified: 2024-12-21 13:16 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 24.12.1
Sentry Crash Report:


Attachments
screenshot_20241221_120135.png (306.09 KB, image/png)
2024-12-21 11:33 UTC, Ralf
Details
screenshot_20241221_120146.png (224.45 KB, image/png)
2024-12-21 11:33 UTC, Ralf
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ralf 2024-12-21 04:36:42 UTC
Telly Skout build from git 631dce6a396d74d8f083537a91c7919d93e16cc5
Delete old programs after: 2 days
Fetcher: TV Spielfilm
Prefetch: 5 days

Hi,

after opening Telly Skout this morning, the time marker protruded beyond the current programs into programs that had already expired.

After clicking the refetch button, the time markers were almost correct, i.e. they were correct for today.

Among all the channels, there is only one channel with a preview for tomorrow (KiKA) and on this channel a break from yesterday's 21:00 to today's 06:00 is fully marked, although it is only 05:15 and a program from tomorrow that starts at 06:00, the end of which is not visible, is also fully marked.

Regards,
Ralf
Comment 1 Plata 2024-12-21 09:38:21 UTC
Could you provide a screenshot? It's a bit hard to understand what's happening based on the description only.
Comment 2 Ralf 2024-12-21 11:32:48 UTC
Hi,

screenshot_20241221_120135.png shows the correct time markers, also the KiKA time marker is now correct. In the morning there was an entry "program break" ("Sendepause") from yesterday 21:00 to today 6:00 completely marked in blue already at 05:15.

If I now scroll down, see screenshot_20241221_120146.png, a program for the KiKA channel is also marked in blue for tomorrow from 06:00, just as it was this morning. As you can see, the screenshots were taken at 12:01.

This morning, when I opened Telly Scout for the first time for today, before I clicked on “Refetch”, the blue markers for all channels were in the correct positions, but all programs above these correct positions, i.e. the programs that were already over, were also marked in blue.

Regards,
Ralf
Comment 3 Ralf 2024-12-21 11:33:37 UTC
Created attachment 176800 [details]
screenshot_20241221_120135.png
Comment 4 Ralf 2024-12-21 11:33:56 UTC
Created attachment 176801 [details]
screenshot_20241221_120146.png
Comment 5 Ralf 2024-12-21 11:47:34 UTC
To put it another way: When I opened Telly Scout for the first time today, all shaded programs were also highlighted in blue.
Comment 6 Bug Janitor Service 2024-12-21 12:52:35 UTC
A possibly relevant merge request was started @ https://invent.kde.org/utilities/telly-skout/-/merge_requests/184
Comment 7 Plata 2024-12-21 12:55:14 UTC
Git commit 2cb62c72b9975d85c86e303ff6d5df8e6e5957c5 by Plata Hill.
Committed on 21/12/2024 at 12:55.
Pushed by plata into branch 'master'.

TV Spielfilm fetcher: fix program stop time before start time

It can happen that the stop time of a program is incorrect (i.e. after the next program has already started).
In this case, TV Spielfilm fetcher overwrites the stop time with the start time of the next program.

As days are fetched from future to past to be able to stop early,
the last program of the next day is the "previous" program of the first program of the current day.
When the stop time was "fixed" in this case, it led to empty entries and misaligned times on the "Favorites" page.

Fix the stop time only if the "previous" program is really previous.

Note: To avoid problems like this, it would generally be better to parse in chronological order.
However, this would be at the cost of performance (stopping early no longer possible).
Additionally, the cases where fixing the stop time is necessary are only rare exceptions.

FIXED-IN: 24.12.1

M  +4    -1    src/tvspielfilmfetcher.cpp

https://invent.kde.org/utilities/telly-skout/-/commit/2cb62c72b9975d85c86e303ff6d5df8e6e5957c5
Comment 8 Plata 2024-12-21 12:57:56 UTC
Git commit 5af350212d08ca5eaf65213143ad9178ce7c66b3 by Plata Hill.
Committed on 21/12/2024 at 12:57.
Pushed by plata into branch 'release/24.12'.

TV Spielfilm fetcher: fix program stop time before start time

It can happen that the stop time of a program is incorrect (i.e. after the next program has already started).
In this case, TV Spielfilm fetcher overwrites the stop time with the start time of the next program.

As days are fetched from future to past to be able to stop early,
the last program of the next day is the "previous" program of the first program of the current day.
When the stop time was "fixed" in this case, it led to empty entries and misaligned times on the "Favorites" page.

Fix the stop time only if the "previous" program is really previous.

Note: To avoid problems like this, it would generally be better to parse in chronological order.
However, this would be at the cost of performance (stopping early no longer possible).
Additionally, the cases where fixing the stop time is necessary are only rare exceptions.

FIXED-IN: 24.12.1

M  +4    -1    src/tvspielfilmfetcher.cpp

https://invent.kde.org/utilities/telly-skout/-/commit/5af350212d08ca5eaf65213143ad9178ce7c66b3
Comment 9 Ralf 2024-12-21 13:16:22 UTC
Thank you! Build and installed package for commit 5af350212d08ca5eaf65213143ad9178ce7c66b3, launched Telly Skout, refetched and so far everything seems to be ok.