Skip to content

Conversation

@dustdfg
Copy link
Contributor

@dustdfg dustdfg commented Jan 13, 2026

What is it?

  • Bugfix (user facing)

Description of the changes in your PR

Turned out this bug was already fixed two years ago but unfortunately
it made its way back again. It was solved in #9642 but back then another
method was used for querying playlists from db (for add playlist dialog) then in
ef4a623 was introduced another method
which had the same problem as fixed in #9642 and which eventually replaced
original method in code for querying playlists from db (for add playlist dialog)

Fixes the following issue(s)

APK testing

The APK can be found by going to the "Checks" tab below the title. On the left pane, click on "CI", scroll down to "artifacts" and click "app" to download the zip file which contains the debug APK of this PR. You can find more info and a video demonstration on this wiki page.

Due diligence

@github-actions github-actions bot added the size/small PRs with less than 50 changed lines label Jan 13, 2026
@dustdfg dustdfg marked this pull request as draft January 13, 2026 14:22
@dustdfg
Copy link
Contributor Author

dustdfg commented Jan 14, 2026

@Stypox Hello! Look at it e44d092 seems like my PR remades change which was already merge long time ago but for some reason was then reverted.... So bug was reintroduced. What would you say? I wanted to find who made that SQL but found that years ago someone already did what I did in this PR and that it was merged (by you)...

So it means that change itself not containing mistake? PR and commit are formatted bad but they could be just changed to "reintroduce "?

@dustdfg
Copy link
Contributor Author

dustdfg commented Jan 14, 2026

@Stypox Sorry first description was not accurate. I a bit messed up methods. Firstly there was only one method which was used for querying playlists. But then in ef4a623 you added new similar method but with old mistake and then overtime the second method was used...

@dustdfg dustdfg force-pushed the playlist_add_empty branch from ab19838 to 9c79c1c Compare January 14, 2026 06:59
@dustdfg dustdfg marked this pull request as ready for review January 14, 2026 07:00
@dustdfg dustdfg changed the title ¯\_(ツ)_/¯ it works but is it correct at all Fixed a bug that prevented the display of multiple empty playlists Jan 14, 2026
@TobiGr
Copy link
Contributor

TobiGr commented Jan 14, 2026

We should add a comment so that this is not reverted again

@TobiGr TobiGr added bug Issue is related to a bug GUI Issue is related to the graphical user interface playlist Anything to do with playlists in the app labels Jan 14, 2026
@dustdfg
Copy link
Contributor Author

dustdfg commented Jan 14, 2026

We should add a comment so that this is not reverted again

The only note I can imagine is to just copy description of #9642, modify to accommodate current state and put it as comment inside file. Something like:

If a playlist has no streams, there won’t be any rows in the playlist_stream_join table that have a foreign key to that playlist. Thus, the playlist_id will not have a corresponding value in any rows of the join table. So, if you group by the playlist_id, only playlists that contain videos are grouped and displayed. Look at #9642 #13055

Is that sufficient?

Turned out this bug was already fixed two years ago but unfortunately
it made its way back again. It was solved in TeamNewPipe#9642 but back then another
method was used for querying playlists from db (for add playlist dialog) then in
ef4a623 was introduced another method
which had the same problem as fixed in TeamNewPipe#9642 and which eventually replaced
original method in code for querying playlists from db (for add playlist dialog)
@dustdfg dustdfg force-pushed the playlist_add_empty branch from 9c79c1c to 402f43e Compare January 15, 2026 10:27
Copy link
Contributor

@TobiGr TobiGr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank you!

@TobiGr TobiGr enabled auto-merge January 15, 2026 12:14
@TobiGr TobiGr merged commit 4ef5aa7 into TeamNewPipe:dev Jan 15, 2026
5 checks passed
@dustdfg dustdfg deleted the playlist_add_empty branch January 15, 2026 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Issue is related to a bug GUI Issue is related to the graphical user interface playlist Anything to do with playlists in the app size/small PRs with less than 50 changed lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Only one empty playlist is shown

2 participants