Skip to content

Commit 4e1e74b

Browse files
authored
Replace Urllib3 method_whitelist with allowed_methods (#638)
* Replace method_whitelist with allowed_methods * Add ChangeLog Entry * update requests to 2.25 and six to 1.15
1 parent 27a7c2c commit 4e1e74b

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2727
### Fixed
2828

2929
- Fixed Spotify.user_playlist_reorder_tracks calling Spotify.playlist_reorder_tracks with an incorrect parameter order
30+
- Fixed deprecated Urllib3 `Retry(method_whitelist=...)` in favor of `Retry(allowed_methods=...)`
3031

3132
## [2.16.1] - 2020-10-24
3233

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@
2626
author_email="paul@echonest.com",
2727
url='https://spotipy.readthedocs.org/',
2828
install_requires=[
29-
'requests>=2.20.0',
30-
'six>=1.10.0',
29+
'requests>=2.25.0',
30+
'six>=1.15.0',
3131
],
3232
tests_require=test_reqs,
3333
extras_require=extra_reqs,

spotipy/client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ def _build_session(self):
194194
total=self.retries,
195195
connect=None,
196196
read=False,
197-
method_whitelist=frozenset(['GET', 'POST', 'PUT', 'DELETE']),
197+
allowed_methods=frozenset(['GET', 'POST', 'PUT', 'DELETE']),
198198
status=self.status_retries,
199199
backoff_factor=self.backoff_factor,
200200
status_forcelist=self.status_forcelist)

0 commit comments

Comments
 (0)