sigma67 / spotify_to_ytmusic

Clone a Spotify playlist to YouTube Music
MIT License
949 stars 72 forks source link

Backend Error #8

Closed Salamafet closed 4 years ago

Salamafet commented 4 years ago

I try to copy playlist with this command: python GoogleMusic.py https://open.spotify.com/playlist/0KZ5DVqPok9qxPC7dxNdJO\?si\=BZ9bsyYyQLyC9z0y1ApH1g

I got the fallowing error:

Traceback (most recent call last):
  File "/Users/stephane/CODE/spotifyplaylist_to_gmusic/mac/lib/python3.8/site-packages/gmusicapi/protocol/shared.py", line 216, in perform
    response.raise_for_status()
  File "/Users/stephane/CODE/spotifyplaylist_to_gmusic/mac/lib/python3.8/site-packages/requests/models.py", line 943, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: https://mclients.googleapis.com/sj/v2.5/playlistbatch?alt=json&hl=en_US&dv=0&tier=fr

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "GoogleMusic.py", line 148, in <module>
    main()
  File "GoogleMusic.py", line 144, in main
    gmusic.createPlaylist(name, info, playlist['tracks'], args.public)
  File "GoogleMusic.py", line 22, in createPlaylist
    playlistId = self.api.create_playlist(name=name, description=description, public=public)
  File "/Users/stephane/CODE/spotifyplaylist_to_gmusic/mac/lib/python3.8/site-packages/gmusicapi/clients/mobileclient.py", line 533, in create_playlist
    res = self._make_call(mutate_call, add_mutations)
  File "/Users/stephane/CODE/spotifyplaylist_to_gmusic/mac/lib/python3.8/site-packages/gmusicapi/clients/mobileclient.py", line 43, in _make_call
    return super()._make_call(protocol, *args, **kwargs)
  File "/Users/stephane/CODE/spotifyplaylist_to_gmusic/mac/lib/python3.8/site-packages/gmusicapi/clients/shared.py", line 83, in _make_call
    return protocol.perform(self.session, self.validate, *args, **kwargs)
  File "/Users/stephane/CODE/spotifyplaylist_to_gmusic/mac/lib/python3.8/site-packages/gmusicapi/protocol/shared.py", line 224, in perform
    raise CallFailure(err_msg, call_name)
gmusicapi.exceptions.CallFailure: BatchMutatePlaylists: 500 Server Error: Internal Server Error for url: https://mclients.googleapis.com/sj/v2.5/playlistbatch?alt=json&hl=en_US&dv=0&tier=fr
(requests kwargs: {'method': 'POST', 'url': 'https://mclients.googleapis.com/sj/v2.5/playlistbatch', 'data': '{"mutations": [{"create": {"creationTimestamp": "-1", "deleted": false, "lastModifiedTimestamp": "0", "name": "Playlist 1", "description": "", "type": "USER_GENERATED", "shareState": "PRIVATE"}}]}', 'headers': {'Content-Type': 'application/json', 'Authorization': '<omitted>'}, 'params': {'alt': 'json', 'hl': 'en_US', 'dv': 0, 'tier': 'fr'}})
(response was: '{"error":{"errors":[{"domain":"global","reason":"backendError","message":"Backend Error"}],"code":500,"message":"Backend Error"}}')

When I try to copy all playlist from username I got the fallowing error for each playlist: Could not transfer playlist And certains playlist are not show in the list.

sigma67 commented 4 years ago

I believe this is the beginning of the end for Google Play Music. Their services are starting to fail, so there's not much we can do about it. The upstream dependency gmusicapi is also facing issues.

Salamafet commented 4 years ago

I have discover Youtube Music a few days. And with your message I just learned that the service is discontinued.

Too bad. Thanks for your quick respond

sigma67 commented 4 years ago

No, Google Music is discontinued. This project has no upload feature for YouTube Music yet. See here for the difference: https://www.androidpolice.com/2020/10/24/google-play-music-to-youtube-music-making-the-switch/

Salamafet commented 4 years ago

Sorry I hadn't noticed the difference. Thank you for the clarification