MusicKitJS won't work on browsers with language set to anything other than English

I'm using MusicKit JS to try and login to my Apple Music account and try to play my library on the browser but for some reason I found out that if my browser's language is set to almost anything other than English, MusicKit won't let the user login and in the console it'll give tho following error:

ember-i18n has been deprecated in favor of ember-intl


I tested it on Firefox, Chrome and Opera and it happens on all of them, when their language is set to anything but English MusicKit isn't working, but when you set it back to English then MusicKit works...


* I couldn't find on the Apple Music API website any regions / languages with restriction of using this SDK so I don't know why it only works when the browser's language is set to English...


Please let me know if this is a bug and if it is how can I report about it to Apple?

Replies

Help? 😟

?

You should probably file this as a bug report using our bug reporting feedback assistant at https://developer.apple.com/bug-reporting/

Thanks, I reported the bug 🙂

Hi,


I'm finding a similar issue, except mine does not work on any language. In addition to this error, I'm also receiving:

"Error while processing route: oauth-screen - 'No destination' (1)

[Error] No destination

https://js-cdn.music.apple.com/musickit/v1/storekit.umd.js:1:10510

requestThirdPartyInfo@https://authorize.music.apple.com/assets/web-authorize-app-1d920c940c51ec4ec7e77213f7a3eb28.js:86:84

runSharedModelHook@https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:3094:8

A@https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:3163:83

O@https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:3164:13

S@https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:3162:145

https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:1105:271

https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:1096:93

https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:1107:224

https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:1114:12

https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:1124:73

https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:4159:257

c@https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:246:123

fireWith@https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:247:700

n@https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:434:442

https://authorize.music.apple.com/assets/vendor-de0f08c371760831e930a3c955878ff6.js:462:207

error

Me (vendor-de0f08c371760831e930a3c955878ff6.js:1899)

ke (vendor-de0f08c371760831e930a3c955878ff6.js:1898)

i (vendor-de0f08c371760831e930a3c955878ff6.js:2508)

trigger (vendor-de0f08c371760831e930a3c955878ff6.js:3196)

(anonymous function) (vendor-de0f08c371760831e930a3c955878ff6.js:3213)

(anonymous function) (vendor-de0f08c371760831e930a3c955878ff6.js:1105:284)

(anonymous function) (vendor-de0f08c371760831e930a3c955878ff6.js:1096:94)

(anonymous function) (vendor-de0f08c371760831e930a3c955878ff6.js:1107:225)

(anonymous function) (vendor-de0f08c371760831e930a3c955878ff6.js:1114)

(anonymous function) (vendor-de0f08c371760831e930a3c955878ff6.js:1124)

(anonymous function) (vendor-de0f08c371760831e930a3c955878ff6.js:4159:258)

c (vendor-de0f08c371760831e930a3c955878ff6.js:246:124)

fireWith (vendor-de0f08c371760831e930a3c955878ff6.js:247:701)

n (vendor-de0f08c371760831e930a3c955878ff6.js:434:443)

(anonymous function) (vendor-de0f08c371760831e930a3c955878ff6.js:462:208)


Were you able to find a solution to your error?

Thank you for reporting.


Are you able to file a radar that contains the browser language information? This output would help with investigations.


navigator.languages
(2) ["en-US", "en"]0: "en-US"1: "en"length: 2__proto__: Array(0)

When I log that in the console, this is what I get back. I don't think that the error I'm receiving is from a language incompatibility. After further investigation, the authentication works perfectly on desktop but when I put the app on mobile, I get the error above. I'm using Ionic v5 with Angular.


I attempted two different methods of authentication and neither worked. The first method was to redirect the user into Safari to authenticate (using the built-in authenticate method) and the second method was to use a Capicator in-app browser and manually call the authentication url.


It seems that I'm not the only one with this issue as well. I just received a reply yesterday from another Ionic user with the same issue. The thread is here: forum(.)ionicframework(.)com/t/using-musickit-javascript-sdk-with-ionic/146906/3


I recognize that Apple would probably prefer me to use the built-in Swift MusicKit framework, but I'm developing this app to be compatible with both iOS and Android.


Please let me know if you know what my issue is. I would really appreciate it!