Problems with Music Tokens under Tahoe?

Just installed macOS Tahoe. The token
%CurrentTrack%album% (and the other %CurrentTrack% tokens now yield the error "KMERROR: Internal AppleScript Execute Error Music got an error: Can't get artist of current track."

I tried to check on the System Settings – KM seems to have all permissions (it had before upgrading).

The token %MusicPlayerState% works, so it seems to be related to AppleScript – but other macros with AppleScript steps continue to work.

So right now, I'm a little clueless what to try next and would appreciate any ideas.
Thanks
Roland

using Mac Tahoe,
The song need to be playing to retrieve those info, otherwise it will throw the error.

Thanks. Sorry I didn't mention that: A song IS PLAYING when I get this error

This is a longshot. But maybe Tahoe is case sensitive. Maybe you should capitalize the word “artist.” It only takes a second to try.

Another idea is to launch Apple Music and see what it reports are the names of, and the values of, the fields you want to return.

I think it's a bug in Tahoe—at least, I hope it's a bug, because if it's not, it means they've decided not to let third party apps get info from Music? I tested with this AppleScript:

tell application "Music"
	if player state is playing then
		set currentTrack to current track
		set albumName to album of currentTrack
		return albumName
	else
		return "No music is currently playing"
	end if
end tell

It works perfectly in Sequoia, but throws the same error listed above when run in Tahoe.

-rob.

1 Like

Update:

This issue only exists with songs that aren't in the library, i.e. Apple Music. Playing a track from my library, everything works as expected. Playing a track in Apple Music that I don't have in my library results in the error.

-rob.

1 Like

Thanks for diving into this. I can confirm that the issue does not occur with tracks from my local library (Apple Music songs throw the error).

I just tried Apples Shortcut app which has also a module to access the currently playing song. It also suffers from that problem (local tracks: ok, Apple Music: error).

I also hope that this is due to some ".0 release glitches" and will be addressed in an update.

1 Like

I had seen someone who wrote an application that displayed music info that Tahoe does not provide as much info, so it is possible that is what is happening.

I can say with some confidence but without the ability to provide proof just now :slight_smile: ... that this issue is fixed in an upcoming macOS release.

-rob.

3 Likes

The Play Playlist action isn't working for me either. Same issue?

That works for me here in Tahoe, with a playlist of songs on my Mac. Are all the songs in your playlist in your library, or are some pointers to Apple Music songs?

-rob.

@griffman For me it only plays the first song in the playlist, whether the entire playlist is in my library or not. Same behavior for Apple Music Playlists that I have added to my library.

Ah, sorry, I didn't actually let it play a full song :), as I thought you were just saying it wouldn't start. But yes, I can confirm, in macOS 26, it plays only the first song. And as above, I can hint to the fact that this shouldn't be a problem for all that much longer :).

-rob.

Quick and happy update to this topic: Apple fixed this bug in Tahoe 26.1. The (music) tokens are now returning the proper values!

1 Like