mirror of
https://github.com/spotipy-dev/spotipy.git
synced 2026-04-27 00:25:54 +03:00
[GH-ISSUE #321] Cache file default naming convention #181
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#181
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 @zsiegel92 on GitHub (Sep 29, 2018).
Original GitHub issue: https://github.com/spotipy-dev/spotipy/issues/321
For some reason I'm unable to submit a pull request for this repository. I suggest changing line 49 of
util.pyfrom:to:
Several issues have been opened regarding the need to interact with the browser more than once to refresh tokens when using
util.py. I believe it is because the token cache file is overwritten when tokens of different scopes are created using the default token cache file naming inutil.py. Of course, users of this library can manually enter acache_path, but I believe other users ran into confusion, as I did. I don't believe the Spotipy documentation says enough about this function to justify making the default behavior ofutil.pynonfunctional for anyone creating multiple tokens.Thank you for making this library. It is a useful tool for getting started interacting with the Spotify API quickly.
@MxHex commented on GitHub (Jan 9, 2019):
I support that suggestion very much.
Also, you are not able to
util.prompt_for_user_token()again after doing that once, because it will fail with`Traceback (most recent call last):
/spotipy/util.py", line 56, in prompt_for_user_token
/spotipy/oauth2.py", line 135, in get_cached_token
/spotipy/oauth2.py", line 156, in _is_scope_subset
AttributeError: 'NoneType' object has no attribute 'split'`
@sanchitcop19 commented on GitHub (Jul 14, 2019):
God bless you @zsiegel92
@stephanebruckert commented on GitHub (Apr 2, 2020):
Closing because too many unanswered questions https://github.com/plamere/spotipy/pull/432#issuecomment-578504990