Jump to content

Recommended Posts

Somehow my +5000 song playlist has become corrupted and I'm trying to rebuild it from backups.  

The problem I have is that I have created a new playlist in PA and I'm trying to export it so that I can import it to other music apps.  Whenever I do this, and import the playlist into either Player Pro or the Samsung Music app, some songs are missing and some with the same titles as other songs in my library are getting mixed up, like something is only reading the song title, and not processing the album or artist data, so I'm getting the wrong song in the imported playlist.

The trouble is, I don't know if the error is occurring with the PA export process, or when the playlist file is being imported, but it seems strange that the same thing is happening with two different players, with the imported PA playlist.

I've been tearing my hair out with this for two nights now, so any advice would be appreciated.

Link to comment
https://forum.powerampapp.com/topic/28559-playlists-nightmare/
Share on other sites

7 hours ago, Si64 said:

something is only reading the song title, and not processing the album or artist data, so I'm getting the wrong song in the imported playlist.

In fact, no tags are used to resolve playlists (not even Title, Artist or Album). Playlists are nothing more than a text list of filenames with the paths to find them in. (Poweramp also adds Rating information, but that was a now-obsolete method to backup ratings from the internal database, which has never been used by other apps).

When Poweramp exports a playlist to a .M3U8 file, it lists the full absolute path for that specific file in storage, which should also work with any other app running on the same device. It will not however work if you copy the same playlist file to another device - such as a computer - where the folder layout is different.

AB12-CD34/My Songs/Artists/ABBA/Arrival/Dancing Queen.mp3
AB12-CD34/My Songs/Artists/Electric Light Orchestra/Time/Hold on Tight.mp3
AB12-CD34/My Songs/Artists/Supertramp/Breakfast in America/The Logical Song.mp3

When Poweramp scans in an existing playlist file (e.g. a .M3U file from another app or that was created by a program on a computer) it ignores the first section of the path, which will be device-specific, and resolves each entry by matching the exact filename and also the name of the last level of containing folder. So for example in the above example, PA would only validate that a file called Dancing Queen.mp3 is contained within any folder called Arrival and not look any further at the rest of the path details. That way it can resolve absolute paths from other devices, and even relative paths.

Andre

2 hours ago, andrewilley said:

In fact, no tags are used to resolve playlists (not even Title, Artist or Album). Playlists are nothing more than a text list of filenames with the paths to find them in. (Poweramp also adds Rating information, but that was a now-obsolete method to backup ratings from the internal database, which has never been used by other apps).

When Poweramp exports a playlist to a .M3U8 file, it lists the full absolute path for that specific file in storage, which should also work with any other app running on the same device. It will not however work if you copy the same playlist file to another device - such as a computer - where the folder layout is different.

AB12-CD34/My Songs/Artists/ABBA/Arrival/Dancing Queen.mp3
AB12-CD34/My Songs/Artists/Electric Light Orchestra/Time/Hold on Tight.mp3
AB12-CD34/My Songs/Artists/Supertramp/Breakfast in America/The Logical Song.mp3

When Poweramp scans in an existing playlist file (e.g. a .M3U file from another app or that was created by a program on a computer) it ignores the first section of the path, which will be device-specific, and resolves each entry by matching the exact filename and also the name of the last level of containing folder. So for example in the above example, PA would only validate that a file called Dancing Queen.mp3 is contained within any folder called Arrival and not look any further at the rest of the path details. That way it can resolve absolute paths from other devices, and even relative paths.

Andre

Thanks Andre.  I just can't work out where the problem is and what's causing it.  It seems to be happening with particular tracks.  For example, I have a track "Airbag/The Greatest Show On Earth/Redemption.m4a", which kept getting mixed up with another track called "Redemption.m4a", which was on an entirely different album (and artist, so not even in the same folder), and which shouldn't have even been in the playlist.  I'm also getting tracks confused with live versions with the same title on different albums.  

I've now recreated the whole +5000 song playlist and imported it into PA, where all seems present and correct, but some (not all) other music apps still won't see all of the tracks when picking up the playlist in the Music folder.  I'm just going around in circles, and oddly, it always seems to be the same number of tracks that are 'missing'.  It's not even that important in the grand scale of things, but I can't rest until it's right.

Just a point - does changing the exported PA playlist from .m3u8 to .m3u do anything detrimentally?  Some apps won't recognise the playlist as .m3u8, but will as .m3u.

Edited by Si64

M3U8 simply means the playlist is in Unicode format, which allows for more extended/international characters in the names. Otherwise the text contents are identical. Many M3U files seem to use Unicode anyway, but they could also be plain old 7-bit ASCII. Renaming an .M3U8 to .M3U should not cause any problems though, as the Unicode nature of the file should be flagged in the first few bytes anyway.

I'm puzzled by some of what you wrote though. Are your issues with PA getting mixed up when scanning external M3U(8) files, and PA ends up referring to the wrong song file? Or are the problems with playlists that you have created within Poweramp and then exported from there to M3U8 ?

As far as reading external M3U(8) files is concerned, if a found playlist refers to a file "<...any-root-path...>/The Greatest Show On Earth/Redemption.m4a", then as soon as PA finds a folder (anywhere in your music collection) called The Greatest Show On Earth which contains a file called Redemption.m4a, the match will be made and the resolving process stops. As I said before, Title, Artist, Album, etc are irrelevant, it's just folders and filenames, so if you have more than one folder called The Greatest Show On Earth then you could potentially end up with a mismatch, depending on which one PA finds first.

Andre

When you say it's always the same number of tracks missing, is it always the same tracks, then? I would think those are just the songs with duplicate filenames.

These other player apps you're trying to use, must not be checking against the containing folder name when it's importing filenames referenced in the playlist you've exported from Poweramp. 

Also:

> I have created a new playlist in PA and I'm trying to export it.

and

> I've now recreated the whole +5000 song playlist and imported it into PA, where all seems present and correct.

So are you making the playlist in Poweramp or not?

Edited by Fitzian
48 minutes ago, andrewilley said:

I'm puzzled by some of what you wrote though. Are your issues with PA getting mixed up when scanning external M3U(8) files, and PA ends up referring to the wrong song file? Or are the problems with playlists that you have created within Poweramp and then exported from there to M3U8 ?

I don't know.  I created a brand new playlist in Player Pro (thinking PA was messing things up).  I backed up the Player Pro playlist, then Imported it into PA (it comes up in PA as Imported on...).  Checked the playlist and all seemed good.  Correct number of tracks and without scrolling through the whole lot, some of the usual suspects (Redemption.m4a) were present and correct.  

I then exported the playlist from PA to see what would happen.  Some apps picked up the whole thing, but tracks are missing in some other apps when importing the playlist.  

Curiously, my playlists are usually kept in a folder called Playlists (rather than in the Music folder), and this has always worked in the past.  If I move the playlist to the Music folder, then all of the tracks are found in other apps.  If I move the playlist back to the Playlists folder, then tracks are missing.  

I'm thinking there's been some sort of issue with some of the music files, possibly since the last Android update?  The trouble is, I've got over 12,000 songs on the phone, in 235 folders, and it would take an age to go through them all.

I think I'm going to do some more file comparisons with WinMerge and see if I can compare the PA playlist with an exported playlist from an app where some of the songs are missing.  

42 minutes ago, Fitzian said:

When you say it's always the same number of tracks missing, is it always the same tracks, then? I would think those are just the songs with duplicate filenames.

These other player apps you're trying to use, must not be checking against the containing folder name when it's importing filenames referenced in the playlist you've exported from Poweramp. 

Also:

> I have created a new playlist in PA and I'm trying to export it.

and

> I've now recreated the whole +5000 song playlist and imported it into PA, where all seems present and correct.

So are you making the playlist in Poweramp or not?

I've done both.  Imported the playlist from Player Pro, checked it, then created a new Playlist in PA from that imported playlist.  

The one thing I haven't done is to recreate the complete thing from scratch in PA.

First, there is no need to use the 'Import Playlists' function in Poweramp at all. All that does is a one-shot task of bringing any existing Android System Playlists into Poweramp's music library database. Since the old Android System Playlist feature is now depreciated by Google, you shouldn't be relying on it any more. It would only be working at all if Player Pro is still storing its playlists there.

All you should need to do is put your newly created M3U(8) files into any location that Poweramp has been granted access to scan for music - i.e. anywhere that's included in PA Settings=>Library=>Music Folders. So if you want PA to scan a folder called 'Playlists', just make sure that it is included in the Music Folders list - either as an item in its own right, or because it is a subfolder of some other folder that's already set up. Anything found in a Music Folders location will be picked up by Poweramp's background scanner and will show up in the Playlists Category in the PA Library.

Are the Playlists that you are creating using Absolute paths or Relative paths? That could make a difference when copying the MSU files to different locations. If you could paste one of them here, or a portion of one if it's very long, that might help. Especially a 'before' version as created by Player Pro and an 'after' version as later exported from Poweramp.

Andre

7 minutes ago, Si64 said:

click on the file, and it open in PA with the (Imported...) appendage.

I actually didn't know you could do that. :) 

If you import a file by using 'Open With', that will just import the contents into the database as a one-off task. So any subsequent changes you make to the playlist songs within PA will remain local to PA rather than being written back into the file. Similarly any changes made to the M3U file later (e.g. by other apps) will not be reflected within Poweramp.

Much better to let the background scanner do it for you though; just make sure your playlist files are saved in a location that PA can scan, and then any edits and changes will be synchronised between PA and the file.

Andre

2 hours ago, andrewilley said:

I actually didn't know you could do that. :) 

If you import a file by using 'Open With', that will just import the contents into the database as a one-off task. So any subsequent changes you make to the playlist songs within PA will remain local to PA rather than being written back into the file. Similarly any changes made to the M3U file later (e.g. by other apps) will not be reflected within Poweramp.

Much better to let the background scanner do it for you though; just make sure your playlist files are saved in a location that PA can scan, and then any edits and changes will be synchronised between PA and the file.

Andre

Yes, because the playlists are contained within PA, that's why I need to sync them with other apps when making any changes, hence the start of this journey!  It was all working fine up to the night before last as I added the new Queen box set.  

The main reason I don't just let PA use a playlist in a 'central' location is that it then appends '.m3u' to the playlist name, and I have a bit of a thing about things like that, as it looks untidy.  I'm pretty sure most people wouldn't worry about it but is one of those things that bugs me, hence I like to import the playlists into PA so that it displays them nicely.  

The other thing is, I probably don't need as many music apps as I have, and if I were to stick to the ones with their own internal playlists, that side of things might be easier, but it would mean manually updating each app each time a playlist is added to.

And, the overriding thing is, as I said, it was all working fine up to the other night, and I don't know what I've done / has happened to change it.

I might just check and see that nothing has strayed out of its designated folder, but I'd have thought if that were the case, I couldn't have remade the playlist in Player Pro.  

The other mystery is that other apps sync with the exported playlist if it's directly in the Music folder, but when I move it to the Playlists folder (so I don't get them doubling up in PA), that's when tracks seem to go 'missing'.

I have a feeling this is going to turn out to be something really daft, and I'll have spent days trying to work something out that should have taken five minutes to fix.

Edited by Si64
41 minutes ago, andrewilley said:

Definitely need to see before and after examples then.

Andre

Yeah, about that...  I'm not sure I want to post entire playlists online.  They're kind of personal...?  😊  And I don't know if just posting a bit of one would be of any use?  I realise that's not very helpful...  😒

Edited by Si64

This is just ridiculous. I'm losing the will to live here.  I've just repaired the playlist in PA, once again, and in PA it's perfect.  

I export it from PA and Import it to Player Pro, and there's tracks missing again.  So, I tried importing it into the Samsung Music app, and all the tracks are there, but the errors are back with the same mixed ups with tracks of the same title.  

What do you want me to show you?  The playlist is a big one - over 5000 tracks. 

Edited by Si64

Attached is a small section of the correct playlist from PA, and subsequently what it became after Importing it to the Samsung Music app.  The first error is in the Alter Bridge AB III album, where its replaced the track Make It Right with a track by the same name but by Jon Anderson. 

I don't know what's going on, but what I need to do now is get this PA playlist imported correctly into another app!

Thanks for all your help, by the way.  🙂

PA Playlist.txt Samsung Playlist Imp from PA.txt

Edited by Si64

The "PA Playlist" version is presumably part of an M3U8 file that you exported from Poweramp, which appears to show the correct absolute path to the audio files, thus:

#EXT-X-RATING:0
primary/Music/Alter Bridge/AB III/05 Still Remains.m4a
#EXT-X-RATING:0
primary/Music/Alter Bridge/AB III/06 Make It Right.m4a
#EXT-X-RATING:0
primary/Music/Alter Bridge/AB III/07 Wonderful Lie.m4a

And that was showing the correct song when viewed in PA's Playlists category? So from Poweramp's point of view, and as per the exported file, all seems correct.

Then when you import that same M3U8 file into Samsung Music, does the song show correctly within the app itself, or is it only when exporting it again from Samsung Music that the same lines change to:

Alter Bridge/AB III/05 Still Remains.m4a
Jon Anderson & The Band Geeks/True/06 Make It Right.m4a
Alter Bridge/AB III/07 Wonderful Lie.m4a

It looks like the Samsung file is using relative paths by the way, so technically it should only be located in primary/Music/ in order to work properly (although PA will still try to interpret such content if it is located elsewhere)


By the way, the files contain some international characters (such as the folder name "Covertà") so it's important that you process them as Unicode (UTF-8, as per the M3U8 spec) when loading into an editor, or the two-byte encoding could get broken, as seems to have occurred here:

image.png

Andre

1 hour ago, andrewilley said:

And that was showing the correct song when viewed in PA's Playlists category? So from Poweramp's point of view, and as per the exported file, all seems correct.

That's correct.

1 hour ago, andrewilley said:

Then when you import that same M3U8 file into Samsung Music, does the song show correctly within the app itself, or is it only when exporting it again from Samsung Music that the same lines change to:

Alter Bridge/AB III/05 Still Remains.m4a
Jon Anderson & The Band Geeks/True/06 Make It Right.m4a
Alter Bridge/AB III/07 Wonderful Lie.m4a

As soon as the playlist is imported into the Samsung app, the lines change.  But I've never had the problem up to a couple of days ago.

What you said about international characters is interesting, but none of those happen to be incorrectly processed.  Well, I say that, there was one Jørn Lande track, Run To You, which incorrectly replaced the Bryan Adams track with the same title.  But that was a one off, and other Jørn Lande tracks were correct.  

  • Solution

Just a quick update - this is now sorted.

I never got to the bottom of what the actual issue was, but I managed to create a new playlist in Jet Audio from an old back up of a previous playlist which was about a week old, so I just needed to add some more recent entries.  I then managed to Export that new playlist, which has Imported successfully into the other music apps, including PA.

Thanks for all the suggestions.  I've no idea if this was a problem with PA, or something else along the way, but it certainly gave me a huge headache and a couple of very late nights!  😖

 

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...