mirror of
https://github.com/spotipy-dev/spotipy.git
synced 2026-04-26 16:15:51 +03:00
[GH-ISSUE #1169] current_user_followed_artists() results in http status 400 #687
Labels
No labels
api-bug
bug
dependencies
documentation
duplicate
enhancement
external-ide
headless-mode
implicit-grant-flow
invalid
missing-endpoint
pr-welcome
private-api
pull-request
question
spotipy3
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/spotipy#687
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @fivebanger on GitHub (Nov 26, 2024).
Original GitHub issue: https://github.com/spotipy-dev/spotipy/issues/1169
Describe the bug
Call of
current_user_followed_artists(limit=20, after=None)first time (i.e.afteris not known yet) results in http status 400.current_user_followed_artists(limit=20, after=None)results in messagewhereas
afterevaluates to0and spotipy raises exceptionYour code
Call
current_user_followed_artists(limit=20, after=None)Environment:
Additional context
Most likely this behavior was changed by Spotify. According to current Spotify developer site, the first call of
/v1/me/followinghas to be called without theafterparameter:Quick fix inside function
current_user_followed_artists():Change
to
which results in message
not sending the
afterparameter. A properly populated list of followed artists is returned.@dieser-niko commented on GitHub (Nov 26, 2024):
The function works as expected. However, it expects a string or None, not an integer, which you seem to have passed to the function.
@fivebanger commented on GitHub (Nov 26, 2024):
Sorry for disruption, you are right. Issue was on my side calling current_user_followed_artists() with artists=0 instead of artists=None.