3.0 regression: playing directory leads to duplicate items
As the title of this ticket says; if you schedule a directory to be played it sometimes add the directory contents twice, leading to duplicate entries in the playlist.
Data used to reproduce
/tmp/samples
|-- sample_1.mp3
'-- sample_2.mp3
0 directories, 2 files
Session that shows the unexpected behavior
As can be viewed below, the first time we add /tmp/samples
it
incorrectly results in 4
items added to the playlist, while repeating
the request later results in 2
.
<pre class="wiki">
% <b>./vlc-trunk -Irc --playlist-tree --file-logging \</b>
> <b>--logfile=/dev/null 2>/dev/null</b>
</pre>
<pre class="wiki">
VLC media player 3.0.0-git Vetinari
Command Line Interface initialized. Type `help' for help.
> <b>add /tmp/samples</b>
> <b>playlist</b>
+----[ Playlist - Undefined ]
| 2 - Playlist
| 4 - samples [played 1 time]
| 5 - Real Life (00:03:45) [played 1 time]
| 6 - Losers (feat. Labrinth) (00:04:43)
| 7 - Real Life (00:03:45)
| 8 - Losers (feat. Labrinth) (00:04:43)
| 3 - Media Library
+----[ End of playlist ]
> <b>add /tmp/samples</b>
> <b>playlist</b>
+----[ Playlist - Undefined ]
| 2 - Playlist
| 4 - samples [played 1 time]
| 5 - Real Life (00:03:45) [played 1 time]
| 6 - Losers (feat. Labrinth) (00:04:43)
| 7 - Real Life (00:03:45)
| 8 - Losers (feat. Labrinth) (00:04:43)
| 9 - samples
| 10 - Real Life (00:03:45)
| 11 - Losers (feat. Labrinth) (00:04:43) [played 1 time]
| 3 - Media Library
+----[ End of playlist ]
> <b>add /tmp/samples</b>
> <b>playlist</b>
+----[ Playlist - Undefined ]
| 2 - Playlist
| 4 - samples [played 1 time]
| 5 - Real Life (00:03:45) [played 1 time]
| 6 - Losers (feat. Labrinth) (00:04:43)
| 7 - Real Life (00:03:45)
| 8 - Losers (feat. Labrinth) (00:04:43)
| 9 - samples
| 10 - Real Life (00:03:45)
| 11 - Losers (feat. Labrinth) (00:04:43) [played 1 time]
| 12 - samples [played 1 time]
| 13 - Real Life (00:03:45) [played 1 time]
| 14 - Losers (feat. Labrinth) (00:04:43)
| 3 - Media Library
+----[ End of playlist ]
>
</pre>
Note
When I prepared the data available in this ticket I was "lucky" enough to have the bug appear on the first try; you may or may not be as fortunate.