[RELEASE] Playlist Manager for Channels [Streaming Library Manager Extension]

I think i put too many sources in to Playlist manager.
How do i clear out the entries or edit them?
When i start the docker, it tries to process the update and it eventually crashes.
Your help is appreciated.

1 Like

My internet went out overnight knocking out some of the sources. I had dumb luck getting it to work :rofl::joy:

During startup, the only thing PLM related is checking to see if it on or not. There's nothing related to it that should be causing any crashes at that point. Please provide your Docker logs, but this sounds like something totally unrelated.

I don't think that is possible. All it will do is take more time when processing them. They are basically treated individually, not as a group.

If you truly want to go down this path (and I don't recommend doing so), if you go into your Volumes in Docker, for your SLM one, you should see something like this:

image

The PLM files all begin with "PlaylistManager" and are plain text. You can edit them, remove everything but the header row, and save. That will resent them to baseline.

Once again, though, I don't believe you should need to do this, ever.

Hi there,
I got the Stream link manager up and running again. Do you have a link where i can edit the urls added?
I just need to remove some stuff that contains https. links.
I grabbed some addresses that seem to have really messed up Playlist manager.
https://apsattv.com/
I had grabbed a tclplus link and roku link and the system appears to be hanging really bad.
If i try to see the playlists it will just create a lot of disk activity and eventually the docker will crash.

He made a video showing all the new features including the one you asked about.

v2024.11.02.0936 has been released as stable. Most of the updates are related to PLM, which is why I'm posting it here.


MODIFIED: {GEN} Added pop-up boxes to various fields so values can be seen by hovering over them

Hovering pop-up info boxes are now all over the place, not just in PLM. Check them out!

image

Let me know if there are other fields where I didn't put this that would be useful. They are very easy to add now.


FIXED: {GEN} Drop down boxes now stay in their column and expand to full-size when you select them

This is now resolved all over the place, not just in PLM:

image

Please let me know if there is another dropdown somewhere I missed. This is a very easy fix now!


FIXED: {PLM} Added infinite scrolling to station lists (unassigned, assigned, parents) for faster loading

This is now resolved where for Unassigned, Assigned, and Parent stations, it will load just 100 lines at a time and add more as you scroll downward.

Let me know if there are other areas this might be useful. This is not very easy to implement, so I'd rather only do it where required for performance reasons, not just everywhere for visual reasons. I didn't come across anywhere else where I thought it would make a noticeable difference, but you never know someone else's use case!


MODIFIED: {PLM} Moved "Add Parent" to the top, minor formatting updates

While adding the infinite scroll from above, it became clear that it would be better if the "add" function were on top, so it is:


FIXED: {PLM} Potential workaround solution for malformed m3u and XML sources that occasionally give errors like 'broken pipe'

A potential solution has been implemented. You may see warnings one to several times in the notifications and logs while it is trying to attach to services like these. Since I can't guarantee if this is fixed, we'll just be monitoring for the time being. Please let me know if you receive the ERROR message and it says it can't load. Providing logs will be very helpful if what I have put in place has not resolved this!


@rpaulmerrell, as you can see, a number of performance improvement have been added in this version. Please upgrade and see if your issues are resolved. If you still cause the program to crash, grab the log file and your PlaylistManager... files from the directory I showed above and send them to me. Also, tell me step-by-step exactly what you did to cause the crash so I can replicate. I need the info from the logs and what you've specifically done to understand what might be happening and address.

1 Like

Just wanted to report that my problem was solved.
I removed the offending links i'm now sorting out all my fast channels.
I'm so glad to have SLM going.

@babsonnexus OK so I put my containers on a macvlan so that they can be seen by slm. This all works fine. My issue now is for my xml guide sources, slm will not create an xml file no matter what I do.

I added my source

The epg is from channels, it opens fine in the browser

However it never generates a xmlepg for mpeg-ts

Looking at the logs it appears that is downloading it (192.168.12.33 is my other Channels server and 192.168.12.8 is my frndly container) When i added the frndly epg xml it worked great, I added the channels as parent stations and then the xml link appeared. Not so much luck with the other Channels source. I have tried using:
http://192.168.12.33:8089/devices/M3U-AUFreeview/guide/xmltv?duration=1209600 (Channels Server)
https://i.mjh.nz/nz/epg.xml (Guide xml as configured on the Channels Server)
https://raw.githubusercontent.com/matthuisman/i.mjh.nz/e2c6e58798b3583db18513ea088478da01fd5e08/nz/epg.xml (cname it resolves to)

None of them work and slm just ignores them.
Any insight you could provide would be very helpful :slight_smile:
Thanks!

[DEBUG | 2024-11-04 16:38:06,186] - Starting new HTTP connection (1): 192.168.12.33:8089
[DEBUG | 2024-11-04 16:38:06,197] - http://192.168.12.33:8089 "GET /devices/M3U-AUFreeview/guide/xmltv HTTP/11" 200 None
[DEBUG | 2024-11-04 16:38:06,214] - Encoding detection: utf_8 is most likely the one.
[DEBUG | 2024-11-04 16:38:06,215] - Starting new HTTP connection (1): 192.168.12.8:80
[DEBUG | 2024-11-04 16:38:06,329] - http://192.168.12.8:80 "GET /epg.xml?gracenote=exclude HTTP/10" 200 None
[DEBUG | 2024-11-04 16:38:06,684] - Encoding detection: utf_8 is most likely the one.
[DEBUG | 2024-11-04 16:38:06,685] - Starting new HTTPS connection (1): raw.githubusercontent.com:443
[DEBUG | 2024-11-04 16:38:06,710] - https://raw.githubusercontent.com:443 "GET /matthuisman/i.mjh.nz/e2c6e58798b3583db18513ea088478da01fd5e08/nz/epg.xml HTTP/11" 200 1130329

I have no issue getting MPEG-TS guides:

However, you won't get an XML Guide under any circumstances if there is a Gracenote ID in the source playlist, or any of the child stations under a shared parent. Even if you set your preferred playlist as one with XML guide data, if some child under that parent has a Gracenote ID, it is going to be used and end up under a Gracenote m3u, and hence no XML guide data. Since your source m3u appears to be coming from Channels, if you mapped stations in there, then those stations will have a Gracenote ID.

Actually, your logs indicate the complete opposite. PLM successfully loaded the XML into a temporary file. The next step in the process says that if a station is in a Non-Gracenote m3u, then search for matching XML guide data in the temp file and copy that to the corresponding Non-Gracenote XML. But that only applies to Non-Gracenote m3u(s). Be sure to check the output of your m3u's to see where your stations are. My bet is that they are in the Gracenote (MPEG-TS) [01] one. As such, they would not get an XML guide. This is also covered on the repo:

P.S.
Speaking of the repo, you don't have to open up a conversation there and here. One or the other is fine. I'm mostly using the Issues area of the repo for bug/request tracking. I'm fine if anyone want to put in requests there, though, instead of here; but for general help, here is probably better.

@babsonnexus ok so there weren't any gracenote id's in there but there is data:

#EXTINF:-1 channel-id="2002" tvg-id="2002" tvg-chno="2002" tvg-logo="https://i.mjh.nz/.images/7mate-syd.png" tvc-guide-stationid="mjh-7mate-syd" tvg-name="7mate" group-title="HD",7mate http://192.168.12.33:8089/devices/M3U-AUFreeview/channels/2002/hls/master.m3u8

then when I look at the xml, it appears that it uses the tvc-guide-stationid to match it with the station.

  <channel id="mjh-7mate-syd">
    <display-name>7mate</display-name>
    <lcn>74</lcn>
    <icon src="https://i.mjh.nz/.images/7mate-syd.png"/>
  </channel>

Is there any way you could set the logic to not generate an xml guide if there are numeric characters in the tvc-guide-stationid field and only generate an xml file if there are alphanumeric characters?

The only other workaround I can see is to download the m3u, then do a find and replace and change the channel id in the m3u to match the xml. Then delete the tvc-guide-stationid section for each channel in the m3u. The upload it to slm... Just kind of defeats the dymanic factor of slm when stuff is hardcoded in..

Yes. I will modify PLM to only accept tvc-guide-stationid field values that are numeric and ignore anything else. They will still load and be stored, but when processing they will be discarded.

You are going to have a problem. PLM uses the tvg-id to match to the XML, and yours don't. I can't say for sure what is happening on your end, but when I export an m3u and XML from Channels, they match. It looks like you might be mixing and matching here, which will cause you a headache. Otherwise, you'll have to take advantage of the parent override:

image

The choice, as always, is yours!

That seems like a perfect plan. I can just override the tvg id for each channel.

Thanks for accepting the FR!

So far everyting seems good.
I'm noticing if i add the m3u from the website
https://apsattv.com/rok.m3u, it adds but it ads multiple entries for the same channel.
Am i missing something?

Thanks

I see the issue. This is a very, very, very malformed m3u and is lacking every bit of typical m3u tagging:

Compare this to Pluto on nocord.xyz:

PLM is currently dependent upon a Playlist having a channel-id and none of these do, so it is getting confused and basically adding everything for everything. I'll see what I can do about it, but this is breaking a basic assumption of how PLM functions.

v2024.11.05.1648 has been released as stable. Here are the highlights for PLM:


MODIFIED: {PLM} Unassigned, Assigned, and Parent stations now have a filter on top

This is now available:


FIXED: {PLM} Gracenote ID (tvc-guide-stationid) values are ignored in final m3u(s) if they are not numeric

Now, if there is any non-numeric character in the tvc-guide-stationid (Gracenote ID) field, the final m3u(s) will not use it and they will be treated as EPG-stations:

383215793-6e5129fe-da27-4142-8146-24d5768ab8c6

383216099-f5ba0198-6681-4389-9a86-2f0b93432ae8


FIXED: {PLM} Malformed playlists that lacked a 'channel-id' tag were causing a station to be created multiple times

You will now only get one of each of these stations:

Basically, I created a condition such that if there is no channel-id, then it creates a fake one with a combination of the Playlist name and the Title of the station, replacing all spaces with underscores, and making everything lowercase.


MODIFIED: {PLM} Playlist Manager is now incorporated into `Reports & Queries'

Specifically, this one:

  • NEW: {PLM} Report showing Parent Stations, their children (in priority order, including override), and Gracenote ID--both imported and override

Additional reports can be created, upon request.


Additional quality-of-life improvements and bug fixes
  • MODIFIED: {PLM} Made 'warning' about having issues connecting to source playlists be log only; 'errors' will continue to be notifications
  • MODIFIED: {GEN} Notification for modified row was repeating in function, removed
  • MODIFIED: {PLM} Filtered out 'modified' notifications if the only difference is the Plex token

In relation to this last point, if you have a source playlist with a similar situation, please let me know and provide examples so I can filter them out from constantly notifying you of a non-existent modification.


Everything else was SLM related, so check over there for that:

1 Like

Having an issue with trying to remove the parent status for a station.


I accidentally made TBD a parent from 2 different sources. When I press delete nothing happens, its like the command is ignored. Are there any tricks to be able to remove a station from being a parent?

I know what's happening, I'll have to put out a fix. In the meantime, something actually did happen: you deleted either the first or second parent in the entire list.

Yeah, I thought the delete logic was still working after implementing the filter, but I was wrong!

This is now fixed in v2024.11.08.1720.

1 Like

I'm using Playlist Manager now to great effect now. It's helped tame, combine and curate the 5 FAST services I've integrated into CDVR a way no other tool has been able to. 500+ channels were redundant, ~300 were in foreign languages, etc. It took a while to customize but the end result is so worth it. I'm discovering and enjoying these FAST channels a lot more than I ever did before!

Some feature requests that have I've thought up along the way:

  • It would be nice to see the total # of channels per m3u, listed next to the URL, or just via pop-up when hovering over it.

  • Some Custom Channel sources are fine refreshing every 3 or 6 or even 12 hours, but Samsung's docker specifically suggests doing it hourly. So can we get a setting to customize different refresh intervals, of each source? For example I'd set Samsung to refresh every 1 hour, but 6 hours for DistroTV. The interval entered in Settings would remain the default but any customized intervals would override that.

  • The list of parent channels is very long, scrolling takes a while when assigning a channel to a parent. (I'm not always sure if the channel is new or redundant yet, so sometimes I'm just looking to see if a parent has already been assigned.) Normally with long menus like this, I can type the first 1-2 characters to jump to where I want to go. But I can't do that here because every channel has the word "Channel" in front of it. Is there a better way for us to navigate this long menu? Keyboard jumps would be ideal IMO.

Thanks again. This tool is spectacular.

Do you mean the generated m3u(s), or do you mean the input ones, or do you mean both?

I don't think this is possible currently. The input XML files are not stored in PLM and are dynamically called during the build cycle. If one is not called, it will not build that guide data. To change that would be a fundamental rewrite and a totally different approach. As such, I have to hard pass.

As an aside, even if the Distro XML guide data only updates every 6 hours, there is no danger in PLM reading and loading it every hour. The processing time is literally just a few milliseconds:

[DEBUG | 2024-11-11 13:30:27,265] - Starting new HTTP connection (1): localhost:7973
[DEBUG | 2024-11-11 13:30:45,570] - http://localhost:7973 "GET /distrotv/epg.xml HTTP/1.1" 200 859642

Keyboard jumps already work; you just have to type "station: " first, then the rest of your letters. You don't even have to be quick about it, either. I intentionally put the prefix so there would be no confusion with the "Ignore" and "Unassigned" values (as well as any other potential thing like this that hasn't come up yet), especially if someone were to name a parent something like "Ignore".

That said, if you want to check if a Parent exists, I'd just open up the Parent tab and take advantage of the filter functionality. That'd be much quicker!