MPMediaPlayback.currentPlaybackRate no longer working in iOS 15.4?

Just wondering if anyone else is having issues with currentPlaybackRate in release version of iOS 15.4? In my particular case this is using MPMusicPlayerController.applicationQueuePlayer.

I've always had issues controlling this property reliably but from what I can see it is now completely non-operational in 15.4.

I've isolated this behavior in a trivial project, and will file a radar, but hoping others may have some insight first.

FWIW- This is my trivial test case:

class ViewController: UIViewController {
    lazy var player: MPMusicPlayerApplicationController = {
        let player = MPMusicPlayerController.applicationQueuePlayer
        player.repeatMode = .none
        player.shuffleMode = .off
        player.beginGeneratingPlaybackNotifications()
        return player
    }()

    override func viewDidLoad() {
        super.viewDidLoad()

        NotificationCenter.default.addObserver(forName: .MPMusicPlayerControllerPlaybackStateDidChange, object: nil, queue: .main) { [weak self] notification in
            guard let notificationPlayer = notification.object as? MPMusicPlayerApplicationController,
                  notificationPlayer === self?.player else {
                return
            }
            
            debugPrint("Player state now: \(notificationPlayer.playbackState)")
        }
    }

    @IBAction func goAction(_ sender: Any) {
        guard let item = MPMediaQuery.songs().items?.randomElement() else {
            debugPrint("Unable to access media items")
            return
        }

        debugPrint("Now playing item: \(item.title ?? "")")
        player.setQueue(with: [item.playbackStoreID])

        player.prepareToPlay() { error in
            guard error == nil else {
                debugPrint("Player error: \(error!.localizedDescription)")
                return
            }

            DispatchQueue.main.async { [weak self] in
                self?.player.play()
            }
        }
    }

    @IBAction func slowAction(_ sender: Any) {
        debugPrint("Setting currentPlaybackRate to 0.5")
        player.currentPlaybackRate = 0.5
        checkPlaybackRate()
    }

    @IBAction func fastAction(_ sender: Any) {
        debugPrint("Setting currentPlaybackRate to 1.5")
        player.currentPlaybackRate = 1.5
        checkPlaybackRate()
    }

    func checkPlaybackRate(afterSeconds delay: TimeInterval = 1.0) {
        DispatchQueue.main.asyncAfter(deadline: .now() + delay) {
            debugPrint("After \(delay) seconds currentPlaybackRate now: \(self.player.currentPlaybackRate)")
        }
    }
}

Typical console output:

"Now playing item: I Know You Know"
"Player state now: MPMusicPlaybackState(rawValue: 2)"
"Player state now: MPMusicPlaybackState(rawValue: 1)"
"Setting currentPlaybackRate to 1.5"
"After 1.0 seconds currentPlaybackRate now: 1.0"
"Setting currentPlaybackRate to 0.5"
"After 1.0 seconds currentPlaybackRate now: 1.0"

Hello @pfvernon2,

This is essentially the same issue as the one described in this other thread: Setting playbackRate in MusicKit for Swift (beta).

We are already tracking this issue internally. If you have any additional information you'd like to share about this, now or in the future, to might be a good idea to do it directly in that other thread.

Best regards,

Hi again @pfvernon2,

Actually, I take that back. I circled back with my colleagues, and they gave me more context about this change.

The feature to change the playback rate only applies to content owned by the user, such as songs purchased on the iTunes Store. If it was possible to do it in earlier releases, it was a bug, and we’ve fixed it in iOS 15.4.

Best regards,

JoeKun, thanks for further researching and acknowledging the issue. That said, I agree with blue0615 that this decision should be reconsidered. I too have a great deal of time, effort, and product design centered around this capability which to this point has never been documented to be "off limits" to 3rd party apps. I have used this capability in my app since iOS 13. To arbitrarily change this functionality without warning or consideration of 3rd party developers is simply unfair, to put it mildly.

Removing the possibility to be able change the speed of Apple Music contents affects many many apps and many many thousands of users. My mailbox was flooded this morning with complaints and customers asking for a refund since my app is now useless. This can't be a bug fix, it's removing of a feature that has been available for at least the last three years, since iOS 13 or even earlier. Please tell us developers that this is actually bug introduced with iOS 15.4 so we can tell our (and Apple's) customers that it will work again in a soon to come update. This isn't what we expect from Apple!

Perhaps this was all just a misunderstanding and a bug that wasn’t caught from any of the unit tests, or there’s a new API that we will need to migrate towards to get the same functionality. I understand that not every release is perfect and that’s okay! Hopefully we get some documentation so our paying customers can be happy with the functionality they’ve come to expect from the products we developers create for the App Store, especially for those of us that make music apps whose customers solely need tempo-changing functionality to get better as musicians (what’s the point of a slow downer app without this functionality?).

However, if iOS 15.4 intentionally prevents developers from manipulating the speed of music in Apple Music and does not intend on adding this functionality back in the future, Apple owes developers that make music apps that rely on this functionality an official announcement at the very least. A timeline would’ve been ideal. Not a rug pull like this!

I’m working on an app that depends on this functionality. If Apple does not right its wrongs, I fully intend on giving my users a way to air their grievances on your forums. Why should I be the one to receive negative reviews because of how Apple rolls out feature changes like this? Nope; I will definitely be taking the time to design a simple, intuitive UX in my app to ensure my users can channel their frustrations onto the group that solely deserves their condemnation.

This mornings email complaints about this “bug fix” in iOS 15.4, here we go:

//

Slowdown/speed up slider no longer working . Music just plays 100%

//

Speed up/slow down no longer works IPad OS 15.4

//

Just updated to iOS 15.4 and now I can’t adjust playback speed of songs from Apple Music. Other imported songs work fine.

//

Songs in Apple Music cannot change the speed in the app in IOS 15.4.

//

Why has the slow down stopped working? I seem to be unable to change speeds on any of the music in the library that I’ve been using for more than a year. This just started today. Please help!!

//

This is ridiculous. The only reason I have your app is to change speeds so I can learn to play them. It’s affected my entire library. What do I do—can I fix it by reinstalling ?

//

I purchased a new iPhone 13 recently, and I would not have had I realized this would affect my use of Apple Music and your app which I use to practice my fiddle. Please, please fix this problem!

//

Since I updated to ios 15.4, I found that I can't change the speed, which is very annoying. I thought the app would improve soon after the update. I didn't expect that apple music could not change the speed after the update. I have been using Apple Music play since I bought this app. I hope this problem can be fixed as soon as possible.

//

My entire library ability to change speed/tempo is now inoperative 

//

Unable to adjust the speed? Help!

//

Hey guys - do you think the slow downer will be restored for itunes anytime soon ?

//

I purchased your app over a year ago and I love it!! I just did the update and realized I can no longer slow down apple music files. Just wondering if you are working on a solution. 

//

I saw the update regarding tempo and Apple Music. This is the sole reason I use this app. Is there a workaround or a possible fix? This a huge ****…

//

Hi - hope you can help. For some reason the slide functions of the app no longer works. The loss of sped adjustment is a make problem! Can this be fixed somehow? Have a pushed a button by mistake that prevents this from working?

//

The speed slider is not working after I downloaded the app

//

Your app doesn't work slowing song's down anymore. I have an iPhone13. Is this an Apple Music problem? 

//

I’ve been using this app for many years and it has helped me tremendously as a tap dance teacher. I play all of my music for class through this app. I’ve been having issues with it for the last couple of days. I’m hoping that maybe you are working on the app and that’s why it’s having issues today. The same issues are happening on my iPad and iPhone 12.

//

Why is the speed adjustment not working with my Apple Music. I have used this feature for my dance class for 2 years. If it truly doesn’t work anymore what options do t have to slow the songs down for practising dances. 

Heather 

//

I’m using your app quite a lot for studying and teaching. I bought the full version of the app from the Apple Store and I’m very happy with it.

As you might know, Apple iOS has updated the software.

Your app is no longer compatible in all the functions.

Please, is there something you can do about it and fix it?

Thank you very much for your attention!

//

What is going on today? I can’t adjust many things on my music, including the speed, which is of course why I have your app, and have for years. Please help! Signed, a really freaked out dance teacher! 

//

The new update will not let me change music that I have composed, imputed into my iTunes and downloaded to a playlist for your app. I use this function to practice my music at slower tempos especially the improvisation elements of my music. Please tell me this will be repaired? 

//

The whole reason I bought this app and spent way more on it than the other slow down apps is so I could use it with my purchased Apple Music library. Now I can’t. I would really like my money back but I assume that is not gonna happen.

//

I can’t change the speed of my music anymore. I read about the bug and the fix. I am paying monthly for Apple Music, does it count to consider I own the music? 

I really liked your app as I’m learning piano, but if I can’t slow down the music I have with apple, it is not useful anymore. 

How can I fix this while staying with Apple Music?

//

This is terrible! We are told to constantly keep up with the latest version of iOS software but that has led to critically down grading my favourite app. Please ask Apple to fix. 

//

I'd like to add my disappointment in how this was handled. I also have an app released on the App Store that relied on this functionality and just like that... it's completely useless for my customers.

What is the point of offering the MusicKit framework if all we can build is a glorified Music app with exactly the same features?

I would like to add my criticism of this abrupt change. There was no indication in the documentation that playbackRate should only be applied to content owned by the user, and no warning about this massive change. It is not fair to developers who have built apps around this feature and users who have paid for apps relying on this feature.

I think it's important that every developer that is affected of this bug should file a bug report and also ask all users that they complain to Apple.

Does anybody know where app users should complain?

Yikes. I'm really disappointed in not only this particular issue - I too have an existing app with existing users who are now mad at ME for something that Apple has changed without notice or intent - but in general with Apple's support to small developers.

Have others noticed a significant uptick in problems and downtick in response/help from Apple?

I want to be compassionate regarding possible workplace challenges for those at Apple who support developers, but right now, I'm left with a sinking feeling that we've been abandoned.

The feature to change the playback rate only applies to content owned by the user, such as songs purchased on the iTunes Store.

So, help me understand: if I record tracks of my own music, composed and played by me, recorded using software I wrote, I can't change the playback rate?

Does anyone have any new info to share?

My bug report is still open and "Recent similar reports" == "None".

Many many customers are complaining, I am about to remove my app from the store.

Why can't anyone from Apple explain why this change was made?

For us developers and all our users, this change does not make sense. It just makes the iOS platform so much worse.

Hello @pfvernon2, @florom, @acosmicflamingo, @nickfromsf, @oneway111, @davenorfleet and @deirdresm,

We have re-evaluated our previous decision to disable changing the playback rate for subscription content from Apple Music in third-party applications, and we came to the conclusion that we could safely enable that functionality again, just like before the release of iOS 15.4.

As such, this issue is fixed in iOS 15.5 beta 4.

I hope this helps.

Best regards,

10

I'm so happy that I cry ! Thank you so much ! @JoeKun 

Hello again old thread, it appears that currentPlaybackRate is broken in the same way on iOS 16.1 beta 1. This does not appear as a known issue in the release notes. Can we get confirmation that this is returning for the public release @JoeKun?

MPMediaPlayback.currentPlaybackRate no longer working in iOS 15.4?
 
 
Q