Code Monkey home page Code Monkey logo

af-1 / lms-dynamicplaylists Goto Github PK

View Code? Open in Web Editor NEW
17.0 3.0 3.0 2.93 MB

Dynamic Playlists - a plugin for Lyrion Music Server that lets you use smart playlists (dynamic playlists) to play continuous music mixes based on your selection criteria.

License: GNU General Public License v3.0

HTML 14.32% Perl 85.20% CSS 0.48%
playlists dynamic-playlists slimserver logitech-media-server smart-mix smart-playlists squeezebox-server lms plugin lyrion-music-server

lms-dynamicplaylists's Introduction

Dynamic Playlists

This plugin1 lets you play continuous music mixes based on selection criteria defined in so-called dynamic playlists (smart playlists).
Dynamic Playlists will keep adding small batches of tracks in random order to your current playlist (complete albums can be added in album order). It comes with a collection of built-in, ready-to-use dynamic playlists to get you started. Since the built-in dynamic playlists cannot cover all possible use cases, you'll probably want to create a dynamic playlist that's tailored to your very specific needs at some point using Dynamic Playlist Creator or a file with SQLite statements (see FAQ).
Some features are not enabled by default.

⬅️ Back to the list of all plugins

Use the    icon (top right) to jump directly to a specific section.



Screenshots - Context Menus2

While the Dynamic Playlists menu in the LMS home menu is easy to find, its context menus can easily be overlooked. You'll find the Dynamic Playlists menus in the context menus for artists, albums, genres, years (for years and decades) and static playlists. Some of them are presented below.

Players with Jivlite UI (Touch, piCorePlayer, SqueezePlay, Radio)

Players with Jivlite UI (Touch, piCorePlayer, SqueezePlay, Radio)



LMS Web UI - Default Skin

LMS Web UI - Default Skin



Material Web UI

Material Web UI



Features

  • Use your own custom dynamic playlist files/definitions directly in DPL without intermediary plugins - you don't have to install other plugins to get dynamic playlists. See FAQ.

  • Comes with more than 200 ready-to-use dynamic playlists (stand-alone + for context menus).

  • Multiple selection of genres, decades, years and static playlists.

  • Preselect multiple artists or albums from their context menu at your leisure. DPL remembers your preselection (until the next rescan/server restart) so that you can easily use it later with dynamic playlists that use preselection.

  • Use dynamic playlists to create static/normal playlists.

  • Queue dynamic playlists (see FAQ).

  • Create a Don't Stop the Music seed list and auto-start your DSTM mix.

  • Supports LMS virtual libraries.

  • Save dynamic playlists with (user input) parameters to LMS favourites (see FAQ).

  • New playlist parameters (see wiki).

  • Compatible with Dynamic Playlist Creator, Alternative Play Count and Custom Skip.

  • If you have installed the Alternative Play Count plugin, you will see some additional dynamic playlists that use the data from this plugin.




Requirements

  • LMS version >= 8.0
  • LMS database = SQLite


Installation

Dynamic Playlists is available from the LMS plugin library: LMS > Settings > Manage Plugins.

If you want to test a new patch that hasn't made it into a release version yet, you'll have to install the plugin manually.



Reporting a new issue

If you want to report a new issue, please read the FAQ first and then fill out this issue report template.

If you use this plugin and like it, perhaps you could give it a ⭐ so that other users can discover it (in their News Feed). Thank you.



FAQ

»How do I create / add my own custom dynamic playlist?«

  • If you prefer a GUI and want an easy way to create a custom dynamic playlist without having to deal with raw SQLite, take a look at the Dynamic Playlist Creator plugin that uses templates to create dynamic playlists and makes them available to DPL.

  • If you are familiar with database queries and SQLite, you can create a fully customized dynamic playlist in a plain text editor of your choice and use it directly in DPL.
    Dynamic playlist definitions are basically plain text files with an "sql" file extension that contain your playlist definition:

    • a couple of parameters (general parameters like the playlist name, group or category and user input parameters) and
    • the SQLite statement itself to fetch tracks from the LMS database.

    Whether you use a built-in dynamic playlist as a template or start from scratch, this will give you a great deal of freedom in creating dynamic playlists tailored to your specific needs.
    In any case please read the wiki for more information on the dynamic playlist format and the few playlist parameters that you should definitely include.
    Put your custom dynamic playlist file (with the sql file extension) in DPL's folder for custom dynamic playlists called DPL-custom-lists (in your LMS preferences folder unless you've changed its location in the settings).
    The new dynamic playlist should now be listed in DPL, either in the Not classified group or in other groups according to what the -- PlaylistGroups parameter in your playlist definition says.


»Can I save the results of a dynamic playlist as a static playlist?«

DPL allows you to save the result set of any dynamic playlist as a static playlist. There's a control icon in the Dynamic Playlists menu (web skins: default, dark default, classic) next to the names of dynamic playlists that looks a bit like an old floppy disk. In Material and jivelite GUI controllers, you get a new option “Save as static playlist“ in addition to Play and Add. You only need to set the maximum number of tracks (max. 4000) and name your static playlist. Dynamic playlists with user-input parameters will request that input first and show you the static playlist options (max. track no., playlist name, track sort order) at the end.
Depending on the complexity of your dynamic playlist and the max. track limit you set for your static playlist, saving it might take a while.


»What's preselection? How does it work?«
    »There's more than one DPL context menu item.«

DPL has playlist parameters that allow you to select multiple genres, decades, years and static playlists. But even the smallest music libraries have a large number of artists and albums that would result in poorly browsable, far too long selection lists.
The solution is to gather/select artists or albums first using the preselection context menu item and then start a dynamic playlist for preselected artists/albums.
So for artists and albums DPL will show a second context menu that allows you to preselect this artist/album while browsing your music library. DPL will remember your (pre)selection until the next LMS restart/rescan. You can't save your preselection permanently, it's a short-term thing. For anything more permanent, please create a custom dynamic playlist with Dynamic Playlist Creator.
Once you've finished preselecting artists/albums, go to DPL's home menu and use this selection with any dynamic playlist that makes use of the PlaylistPreselectedArtists or PlaylistPreselectedAlbums playlist parameter. There are some built-in dynamic playlists to get you started (in the Songs group). And it's very easy to add these playlist parameters to your custom dynamic playlists. Read this wiki section for more information.


»With which plugins does DPL work?«

DPL is compatible with Dynamic Playlist Creator, Alternative Play Count and Custom Skip.

If you're familiar with SQLite and know how to create custom dynamic playlists, you can use data from any LMS database table.


»How do I queue dynamic playlists?«
    »I've queued dynamic playlists and they disappeared.«

You can queue up to 5 dynamic playlists. When all tracks matching the search criteria for the active dynamic playlist have been added to your client playlist and you have queued dynamic playlists, DPL will add a short silent track and (a placeholder for) the next queued dynamic playlist to your client playlist. The silent track should help with a smooth transition so the last track before the new dynamic playlist isn't cut short.

Please note: The list with queued dynamic playlists is cleared when you restart the server.


»How does DPL work with the Don't Stop the Music plugin?«
    »What does the icon with the infinity symbol do?«
    »What does “Create DSTM seed list and play“ mean?«

The Don't Stop the Music (DSTM) plugin “will automatically add similar music to what you've been listening to ... once you've reached the end of your playlist“. DSTM takes a look at the existing tracks in your client's playlist (the seed list) to determine what kind of tracks to search for.

As long as Dynamic Playlists is active, i.e. playing a dynamic playlist, DSTM will not interfere or add any tracks.

But now you can use Dynamic Playlists to create a DSTM seed list from any dynamic playlist and start a DSTM mix for you. There's a preference setting if you prefer to skip playback of all seed list tracks (but the last one).


»How do I know whether DPL is still active?«
    »What causes DPL to no longer be active?«

To find out whether Dynamic Playlists is still active just enter the DPL menu from the Home/My Music menu. If it's still active, it will display the active dynamic playlist at the top of the DPL menu.
Some actions/events that stop DPL (= no longer active): clearing your client playlist, DPL no longer finds tracks for the active dynamic playlist, you told DPL to stop adding tracks...


»What does the PlaylistUseCache option do? Which dynamic playlists can use the cache?«

For dynamic playlists that can retrieve all tracks matching your search parameters in one initial database query, DPL loads all tracks into the cache, thus eliminating the need for further database queries. Subsequent batches of new tracks for the active dynamic playlist will be retrieved from the cache only, and added to a client's playlist much faster as a result.
Dynamic playlists that retrieve each batch of new tracks from a different, randomly chosen artist, album, genre, year, decade or static playlist are not suitable for cache use because not all tracks can be retrieved in one initial database query.


»I've added a dynamic playlist to my LMS favorites, but it no longer works.«
    »There are some dynamic playlists that I can't add to LMS favorites.«
    »DPL shows a favorite icon with a p (default skin) or an orange tint (classic skin) next to my dynamic playlists. Why?«

Prior to Dynamic Playlists 3, you could only save one-click dynamic playlists as favorites that don't ask for user input when you start them.

Now you can also add dynamic playlists with user input parameters.
By default, Dynamic Playlists will not let you save dynamic playlists as LMS favorites that ask users for volatile input at run-time (artist, album, genre(s) or playlist(s)) because those values could change after a rescan and break such favorites.
If you still want to add dynamic playlists with volatile parameter values (artist, album, genre(s) or playlist(s)) to LMS favorites, you can enable this in the plugin settings. However, keep in mind that such favorites may no longer work after a rescan and you'd have to delete and readd them. Therefore I suggest you choose a descriptive name so you'll remember what parameter values you chose (like "Alternative 80s rated").

If you always select the same artists, albums, genres or playlists, it's probably better to create a custom dynamic playlist with the actual artist/album/genre/playlist names. A favorite for such a one-click dynamic playlist is not affected by rescans.

This feature is limited to the LMS web UI ((Dark) Default and Classic skin), players with jivelite UI (Touch, Radio, SqueezePlay, piCorePlayer) and Material skin.

Please note: Changing the filename of a custom dynamic playlist alters its dynamic playlist id and thus invalidates any existing favorite for this dynamic playlist. The same applies to built-in dynamic playlists: If a plugin update changes the filename of a built-in dynamic playlist, you'll have to delete and readd favorites based on that dynamic playlist. Doesn't happen very often and always for good reasons.

The favorite icon with the p (default skin) or an orange tint (classic skin) just indicates that this dynamic playlist contains parameters that will ask for user input when you start it.


»The Not classified group in the DPL (home) menu has disappeared / doesn't show.«

The Not classified group in the DPL (home) menu and on settings pages will only be displayed if DPL found dynamic playlists without a playlist group name, i.e. if it's not empty.


»This built-in dynamic playlist is missing a feature that I really want.«

The collection of built-in dynamic playlists includes only a large but limited set of frequently used playlists that won't see regular additions or updates.
If you want to create custom dynamic playlists without bothering with SQLite statements, please try the Dynamic Playlist Creator plugin.
If you're familiar with SQLite, you can use the built-in dynamic playlists as a starting point for creating your own custom dynamic playlists.


»I don't want my dynamic playlist in the Not classified group. I want a custom group (name).«

The Not classified group is a catch-all group for all dynamic playlist that are not assigned to any playlist group. You can create your own custom playlist groups by entering a playlist group name in Dynamic Playlist Creator or by setting the -- PlaylistGroups: parameter in the file with your customized SQLite statement (see wiki).


»Does DPL handle online tracks?«

Dynamic Playlists will process online tracks that have been added to your LMS library as part of an album. LMS does not import single online tracks or tracks of online playlists as library tracks and therefore they won't be processed by Dynamic Playlists.


»Some dynamic playlists in the DPL menu are not listed in alphabetical order.«

In general, dynamic playlists in the DPL menu will always be listed in this order: 1. built-in, 2. custom/user-provided, 3. provided by other plugins. Dynamic playlists in the last two groups should be listed in alphabetical order.
Built-in dynamic playlists are listed in a 'content-based' order created by me. For example, I try to group dynamic playlists together that are about ratings, play count or genre/decade selection. If you don't like how I ordered the built-in dynamic playlists, don't forget that you can clone these playlists and even put them in a custom playlist group just by adding the corresponding parameter (see wiki).
Static (saved) playlists will always be ordered alphabetically.


»Can I use CLI commands to control DPL?«

Explained in the wiki.


»The Home > Dynamic Playlists menu doesn't show dynamic playlists for context menus. Why?«

By default the Home > Dynamic Playlists menu will only show dynamic playlists that don't include the -- PlaylistMenuListType:contextmenu parameter. Here you won't find any dynamic playlists that can be called from an item's context menu.
And context menus (= More menu in the web UI or click/touch-hold on jivelite players) will only show dynamic playlists for context menus. So there may be some overlap but this separation greatly helps reduce clutter.


»I want my dynamic playlist to use one of Custom Skip's filter sets.«

Use Dynamic Playlist Creator to create a custom dynamic playlist with a specific Custom Skip filter set that's enabled/disabled when your dynamic playlists starts/stops.
If you have created a custom dynamic playlist from scratch (raw SQLite), just add the necessary action/CLI playlist parameters to your file as described here.
If you only need one filter set for all dynamic playlists, create a Custom Skip filter set that will only be active if DPL plays a dynamic playlist. See Custom Skip Wiki.




Footnotes

  1. If you want localized strings in your language, please read this. Based on Erland's DynamicPlayList plugin.

  2. The screenshots might not correspond to the UI of the latest release in every detail.

lms-dynamicplaylists's People

Contributors

af-1 avatar groentebroer avatar meindefy avatar werdeil avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

lms-dynamicplaylists's Issues

&playerid ignored in http request for dynamicplaylist

Please read the FAQ (if available) and take a look at the closed issues first to avoid duplicates. Thank you.


DESCRIBE THE BUG

Since latest update &playerid ignored in http request for dynamicplaylist - instead the last active player will be addressed



TO REPRODUCE

Steps to reproduce the behavior:
call
http://ip:9000/plugins/DynamicPlaylists4/dynamicplaylist_mixparameters.html?type=dplusercustom_interpret_new&addOnly=0&dynamicplaylist_parameter_1=%25Queen%25&playerid=xxxxxxxxxxx

instead of playerid in the parameters, the last active player will play the playlist



EXPECTED BEHAVIOR

playlist should be played on the player with playerid



LOG EXCERPT

n/a



NAME/CODE OF DYNAMIC PLAYLIST

interpret_new.sql
-- PlaylistName:Interpret... -- PlaylistGroups: Custom Dynamic Playlists -- PlaylistParameter1:list:Interpret waehlen:%Art%Noise%:Art of Noise,%Blackpink%:Blackpink,%Bon Jovi%:Bon Jovi,%BTS:BTS,%Justin Bieber%:Justin Bieber,%Lady Gaga%:Lady Gaga,%Phil Collins%:Phil Collins,%Queen%:Queen,%Rihanna%:Rihanna,%Robbie Williams%:Robbie Williams,%Selena Gomez%:Selena Gomez,%Supertramp%:Supertramp,%Udo J%rgens%:Udo Juergens select tracks.id, tracks.primary_artist from tracks join contributor_track on tracks.id=contributor_track.track join contributors on contributor_track.contributor=contributors.id and contributor_track.role in (1,5) left join dynamicplaylist_history on tracks.id=dynamicplaylist_history.id and dynamicplaylist_history.client='PlaylistPlayer' where audio=1 and dynamicplaylist_history.id is null and contributors.name like ''PlaylistParameter1'' and contributors.name not like 'Queens Of The Stone Age' and contributors.name not like 'Queensrÿche' order by random() limit 30;



VERSION INFO

  • LMS version: 8.3.1 - 1676361197 @ Fri 17 Feb 2023 06:42:42 AM CET
  • OS (version): piCore - DE - utf8
  • Plugin version: Dynamic Playlists 4.1.3
  • Web skin/controller: Material, Touch
  • Browser (version): Firefox



SCREENSHOTS

n/a



ADDITIONAL CONTEXT

n/a



UPLOADS

n/a

[ISSUE] DynamicPlaylist creation fails if an excluded genre contains a single quote

Checklist

❗️ Please take a quick look at this checklist to eliminate common causes of LMS (plugin) problems. Thank you.




DESCRIBE THE BUG

If you add a genre containing a single quote (e.g. Children's) to the list of genres to exclude (Excluded genres) in the DynamicPlaylist plugin's settings, the dynamic playlist fails to play due to a non-escaped single quote in the playlist's SQL statement.



TO REPRODUCE

Steps to reproduce the behavior:

  1. Add a song to the library that has a genre containing a single quote.
  2. Rescan library
  3. In the DynamicPlaylist plugin's settings, add the genre to the Excluded Genres list.
  4. Play a dynamic playlist (e.g. Songs - never played (APC))
  5. Playlist won't play. Instead, the main dynamic playlist selection screen is shown.



EXPECTED BEHAVIOR

The dynamic playlist will be added to the playlist and will play.



LOG EXCERPT

2024/02/29 08:53:57,stdout,"[24-02-29 08:53:57.6244] Slim::Schema::Storage::throw_exception (121) Error: DBI Exception: DBD::SQLite::db prepare failed: near "s": syntax error [for Statement "select tracks.id, tracks.primary_artist from tracks left join library_track on library_track.track = tracks.id join alternativeplaycount on alternativeplaycount.urlmd5 = tracks.urlmd5 and ifnull(alternativeplaycount.playCount, 0) = 0 left join dynamicplaylist_history on dynamicplaylist_history.id = tracks.id and dynamicplaylist_history.client = '10:7b:44:93:2e:02' where tracks.audio = 1 and dynamicplaylist_history.id is null and tracks.secs >= 90 and not exists (select * from tracks t2,genre_track,genres where t2.id = tracks.id and tracks.id = genre_track.track and genre_track.genre = genres.id and genres.name in ('Non-Music','Children's','Comedy','Books & Spoken','Audiobook','Hörspiel')) and case when ('' != '' and '' is not null) then library_track.library = '' else 1 end group by tracks.id"]
"



NAME/CODE OF DYNAMIC PLAYLIST

Songs - never played (APC)



VERSION INFO

  • LMS version: 8.4.1
  • OS (version): Synology DSM 7.2.1-69057 Update 3
  • Plugin version: v4.3.5
  • Web skin/controller: LMS Default
  • Browser (version): Google Chrome Version 122.0.6261.70

Not an issue as such but a query about using static playlists

DESCRIBE THE BUG

I have several static playlists which I like to use with the dynamic playlist plugin so that they load quickly and are shuffled each time
these work well when selected through the web interface

I also use Home Assistant with scripts to send cli commands to play these scripts on different players

I have noticed that if the url for the script contains encoded characters for example %2B rather than the actual + character
then not surprisingly my scripts dont play the relevant static playlist

for instance I have a playlist called dinner
its static playlist id is 160365
the url in Home > Dynamic Playlists > Static Playlists
is http://lms.localdomain:9000/plugins/DynamicPlaylists4/dynamicplaylist_list.html?p0=dynamicplaylist&p1=playlist&p2=play&p3=dplstaticpl_PGPBtJ1Dd6Co5RDdrt9%2F%2FJKp1d8&player=b8%3A27%3Aeb%3Ad5%3Aac%3A88

and in this case i have to replace the two %2F with // in my script so that

the ultimate cli call is CLIENT_ID dynamicplaylist playlist play dplstaticpl_PGPBtJ1Dd6Co5RDdrt9//JKp1d8

The only way I have discovered to detect the DYNAMICPLAYLIST_ID for a static playlist is by hovering the mouse over the play button

is there anyway to discover the url of the playlist via a script or be able to construct it from the static playlist id

Any advice anyone can give gratefully accepted

Although not really relevant the actual Home-Assistant script I use follows

===============================

`

in the following array SqueezePlayLists

you must replace any URL Encoding strings by the actual characters they represent

for exampe %2b is + and %2f is /

the string dplstaticpl_PGPBtJ1Dd6Co5RDdrt9%2F%2FJKp1d8

has to become dplstaticpl_PGPBtJ1Dd6Co5RDdrt9//JKp1d8

lms_dynamic_play:
alias: Lms Dynamic
mode: single
icon: mdi:music
sequence:

  • variables:
    SqueezePlayLists:
    Dinner: 'dplstaticpl_PGPBtJ1Dd6Co5RDdrt9//JKp1d8'
    Karen: 'dplstaticpl_xXMhdJQR/Up59ZgBx+j4ypsz55k'
    Speaker-Test: 'dplstaticpl_maRsj0ELIYXNTbXiYejkTvghpek'
    Guitars: 'dplccustom_guitars'
    Heavy: 'dplccustom_heavy'
    Long_Songs: 'dplccustom_long_songs'
    My_Folk: 'dplccustom_my_folk'
    My_Jazz: 'dplccustom_my_jazz'
    My_Prog: 'dplccustom_my_prog'
    RockSteady: 'dplccustom_rocksteady'
    Short_Songs: 'dplccustom_short_songs'
    1950s: 'dplccustom_1950s'
    1960s: 'dplccustom_1960s'
    1970s: 'dplccustom_1970s'
    1980s: 'dplccustom_1980s'
    '1969': 'dplccustom_1969'
    '1975': 'dplccustom_1975'

    Item: "{{ SqueezePlayLists[ states('input_select.lmsplaylist_select') ] }}"

  • service: squeezebox.call_method
    data:
    command: dynamicplaylist

    parameters: "{{ ['playlist', 'play', item] }}"

    parameters:

    • playlist
    • play
    • "{{ Item }}"
      target:
      entity_id: media_player.{{ states('input_select.lms_instance') }}
      `

===========================================

A clear and concise description of what the bug is.



TO REPRODUCE

Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error



EXPECTED BEHAVIOR

A clear and concise description of what you expected to happen.



LOG EXCERPT

  • Add relevant (error) messages from the LMS server log (file path at the bottom of LMS settings > Information). Use the time stamps in the log to find messages created around the time your problem occurred.
  • If there are no server log error messages, set the debug level for this plugin to info in LMS settings > Advanced > Logging, reproduce the problem and check the server log again. If there's still nothing, repeat this step with the debug level set to debug.
  • Alternatively, upload the complete LMS server log file somewhere (see UPLOADS below) and don't forget to add the time stamp of when the problem occurred.



NAME/CODE OF DYNAMIC PLAYLIST

If the issue involves a dynamic playlist, please provide the full (menu) name for built-in dynamic playlists or the SQLite code for custom dynamic playlists that you have created.



VERSION INFO

  • LMS version: 8.5.1
  • OS (version): Linux archlinux 6.9.2 running as a vm on ProxMox server
  • Plugin version: 4.4.1
  • Web skin/controller: LMS Default
  • Browser (version): Microsoft Edge

If the problem occurs with a specific web skin/controller (e.g. Material), please check whether it also occurs when using other web skins/controllers (e.g. LMS default skin).



SCREENSHOTS

If applicable, add screenshots to help explain your problem.



ADDITIONAL CONTEXT

Add any other context about the problem here.



UPLOADS

In case you want to provide larger files to illustrate the problem (e.g. your library.db, persist.db or LMS server log file), please use a service like https://wetransfer.com/ and include the download link in your bug report.

Dynamic playlist "forgets" the parameters I set for a playlist, although still adding songs

Checklist

✔️

DESCRIBE THE BUG

I mostly use the Dynamic playlist generator to use playlist songs_081_random_not_in_playlist.sql.
This make me listen to my favorite music while excluding all songs that are not particually my favorites...

After a small fix which got merged, this Dynamic playlist now works perfectly, although when using this playlist for a longer time (e.g. keep it enabled for some days), it starts adding songs that for 100% are in the Ignored playlist, so these songs do not get ignored anymore. (Verified in the playlist .m3u8 file which is safed to disk, and in the SQL DB.)

I cannot really tell why this is happening, but a wild guess would be that the cache (PlaylistUseCache: 1) is for some reason gone over time, which then creates a new cache, but with the cache being gone also PlaylistParameter1 is gone, causing it to not exclude the songs on the ignore playlist anymore.

The good thing though is that the Dynamic playlist keeps adding new songs to the playlists....

TO REPRODUCE

Steps to reproduce the behavior:

  1. Play: songs_081_random_not_in_playlist.sql with a "large" playlist to ignore.
  2. Keep this playing or "paused" a couple of days.
  3. Listen to the playlist again, so it will add new songs
  4. At some point new songs will include the songs that are in the playlist to ignore.

NOT CERTAIN: But the issue might also be triggered with an "internal" restart of squezeeboxserver after changing some setting. (It asks you if you want to restart, it does not actually restart the linux service, but restarts within the same process or something.)

If I restart the dynamic playlist again, when the issue occurs, it works perfectly again for some time...

EXPECTED BEHAVIOR

The playlist should keep excluding songs in the "exclude" playlist over time, as the dynamic playlist functionality is still active.

LOG EXCERPT

I am not sure if any logs might help here, I have none specifically.

NAME/CODE OF DYNAMIC PLAYLIST

songs_081_random_not_in_playlist.sql

VERSION INFO

  • LMS version: 8.3.1
  • OS (version): Linux (CentOS 7)
  • Plugin version: 4.2.1
  • Web skin/controller: LMS Default, Material, piCorePlayer, SqueezePlay(Slimdevice3)
  • Browser (version): Firefox

The problem does not seem skin/web related, I have it with multiple clients (e.g. desktop player, squeezebox, piCorePlayer)

Every first Custom DPL usage fails, using Material-Skin playlist via browser and then Custom DPL

DESCRIBE THE BUG

I'm using several different custom DPLs successfully, e.g. below one for "Lieblingstitel". Every first attempt to start Custom DPL after playing Material-Skin built in playlist "Stilrichtung" fails. Second attempt with any other Custom DPL works as expected.



TO REPRODUCE

Steps to reproduce the behavior:

  1. Coming from Material-Skin built in playlist "Genre"/"Stilrichtung" (selected through Material-Skin V3.03: "Meine Musik"/"Stilrichtung") - player (e.g. Squeezebox Touch) is playing as expected.

  2. First usage of Custom DPL : After selecting "Play" for the Custom DPL (see example above) in material skin dialog box showing "Play" but without any other information - Custom DPL doesn't start.

  3. Selecting "Play" for any other Custom DPL after first fail works as expected: dialog box is showing up with "Starting dynamic playlist: xxxxxxxxx" and Custom DPL plays as expected.After selecting "Play" for the Custom DPL (see example above) in material skin dialog box showing "Play" but without any other information - Custom DPL doesn't start.



EXPECTED BEHAVIOR

Even the first usage of Custom DPL after using Material-Skin built in playlist "Stilrichtung" should start the selected Custom DPL and play.



LOG EXCERPT

n/a



NAME/CODE OF DYNAMIC PLAYLIST

-- PlaylistName:03 Lieblingstitel
-- PlaylistGroups: Custom Dynamic Playlists
select tracks.id, tracks.primary_artist from tracks
	join genre_track on
		tracks.id=genre_track.track
	join genres on
		genre_track.genre=genres.id
	left join dynamicplaylist_history on
		tracks.id=dynamicplaylist_history.id and dynamicplaylist_history.client='PlaylistPlayer'
	where
		audio=1
		and dynamicplaylist_history.id is null
		and	genres.name not like '%(%)%'
		and	genres.name not like 'Alternative%'
		and	genres.name not like 'Blues%'
		and	genres.name not like 'Boogie%'
		and	genres.name not like 'Books & Spoken%'
		and	genres.name not like 'Cabaret%'
		and	genres.name not like 'Children''s Music%'
		and	genres.name not like 'Christmas%'
		and	genres.name not like 'Classical%'
		and	genres.name not like 'Country%'
		and	genres.name not like 'Deutsch%'
		and	genres.name not like 'Dixie%'
		and	genres.name not like 'Dub%'
		and	genres.name not like 'Ethno%'
		and	genres.name not like 'Industrial%'
		and	genres.name not like 'Jazz%'
		and	genres.name not like 'Kabarett%'
		and	genres.name not like 'Metal%'
		and	genres.name not like 'Operette%'
		and	genres.name not like 'Schlager%'
		and	genres.name not like 'Soundtrack%'
		and	genres.name not like 'Tanzmusik%'
		and	genres.name not like 'Techno%'
		and	genres.name not like 'Volksmusik%'
	group by tracks.id
	order by random()
	limit 30;



VERSION INFO

  • LMS version: Version: 8.3.0 - 1667251155 @ Fri 04 Nov 2022 09:19:49 AM CET (piCorePlayer)
  • OS (version): piCore - DE - utf8
  • Plugin version: Dynamic Playlists 4.0.3
  • Web skin/controller: Material
  • Browser (version): Firefox 108.0.1 (64-Bit)



SCREENSHOTS

If applicable, add screenshots to help explain your problem.
grafik
First usage:
grafik
Second usage (with other Custom DPL)
grafik
Playing as expected:
grafik
Playing same playlist as in first try successfully:
grafik



ADDITIONAL CONTEXT

n/a



UPLOADS

n/a

Start/Restart Custom Dynamic Playlist via http request

I'm using the following http request to start one of my Custom Dynamic Playlists "03 Lieblingstitel":
http://IP:9000/plugins/DynamicPlaylists4/dynamicplaylist_list.html?p0=dynamicplaylist&p1=playlist&p2=play&p3=dplusercustom_03%20lieblingstitel_new&player=xxxxxxxxxxxxxxxx

When I use this request the first time, the DPL starts playing as expected.

When the DPL is paused or player is switched off (same DPL is still selected) and same http request is sent, nothing happens.
I would have expected to start the Custom Dynamic Playlist again (or at least continue to play same DPL).

background: I'd like to start DPL via simple iPhone Automation for scanning NFC tag and send http request (which works for the initial scan, but doesn't work for further scans)

Could you please have a look on this issue,
Martin

[FEATURE REQUEST]

I don't know, if this is the right spot to ask for features. Sorry, if wrong.

When creating dynamic playlists, I miss the option to filter for "Comment is not empty" I can only filter for "contains, contains not, starts with and starts not with".

Greetings

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.