Skip to content

Commit 71056e2

Browse files
authored
Drop support for py2.6 and py3.3. (#263)
This commit removes testing for those platforms. This commit also makes changes so that CI passes again, including several pylint warning suppressions. This commit also starts using pycodestyle instead of the deprecated pep8 package name.
1 parent 9eb12ac commit 71056e2

File tree

16 files changed

+47
-33
lines changed

16 files changed

+47
-33
lines changed

.travis.yml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,22 +10,18 @@ before_cache:
1010

1111
matrix:
1212
include:
13-
- python: 2.6
14-
env: TOX_ENV=py26
1513
- python: 2.7
1614
env: TOX_ENV=py27
17-
- python: 3.3
18-
env: TOX_ENV=py33
1915
- python: 3.4
2016
env: TOX_ENV=py34
2117
- python: 3.5
2218
env: TOX_ENV=py35
2319
- python: 3.6
2420
env: TOX_ENV=py36
2521
- python: pypy
26-
env: TOX_ENV=pypy PYPY_VERSION='2.7-5.8.0'
22+
env: TOX_ENV=pypy PYPY_VERSION='2.7-5.10.0'
2723
- python: 2.7
28-
env: TOX_ENV=pep8
24+
env: TOX_ENV=pycodestyle
2925
- python: 2.7
3026
env: TOX_ENV=pylint
3127
- python: 2.7

HISTORY.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ Release History
88

99
**Breaking Changes**
1010

11+
- Python 2.6 is no longer supported.
12+
- Python 3.3 is no longer supported.
1113
- ``Events.get_events(...)`` now returns a list of ``Event`` instances rather than a list of ``dict``
1214
representing events. ``Event`` inherits from ``Mapping`` but will not have all the same capabilities as
1315
``dict``.

boxsdk/auth/cooperatively_managed_oauth2.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ def __init__(self, retrieve_tokens=None, *args, **kwargs):
1616
:type retrieve_tokens:
1717
`callable` of () => (`unicode`, `unicode`)
1818
"""
19+
# pylint:disable=keyword-arg-before-vararg
1920
self._retrieve_tokens = retrieve_tokens
2021
super(CooperativelyManagedOAuth2Mixin, self).__init__(*args, **kwargs)
2122

boxsdk/auth/oauth2.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@
99
import sys
1010

1111
import six
12-
from six.moves.urllib.parse import urlencode, urlunsplit # pylint:disable=import-error,no-name-in-module
12+
# pylint:disable=import-error,no-name-in-module,relative-import
13+
from six.moves.urllib.parse import urlencode, urlunsplit
14+
# pylint:enable=import-error,no-name-in-module,relative-import
1315

1416
from boxsdk.config import API
1517
from boxsdk.exception import BoxOAuthException

boxsdk/auth/redis_managed_oauth2.py

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,17 +14,19 @@ class RedisManagedOAuth2Mixin(OAuth2):
1414
"""
1515
Box SDK OAuth2 subclass.
1616
Allows for storing auth tokens in redis.
17-
18-
:param unique_id:
19-
An identifier for this auth object. Auth instances which wish to share tokens must use the same ID.
20-
:type unique_id:
21-
`unicode`
22-
:param redis_server:
23-
An instance of a Redis server, configured to talk to Redis.
24-
:type redis_server:
25-
:class:`Redis`
2617
"""
2718
def __init__(self, unique_id=uuid4(), redis_server=None, *args, **kwargs):
19+
"""
20+
:param unique_id:
21+
An identifier for this auth object. Auth instances which wish to share tokens must use the same ID.
22+
:type unique_id:
23+
`unicode`
24+
:param redis_server:
25+
An instance of a Redis server, configured to talk to Redis.
26+
:type redis_server:
27+
:class:`Redis`
28+
"""
29+
# pylint:disable=keyword-arg-before-vararg
2830
self._unique_id = unique_id
2931
self._redis_server = redis_server or StrictRedis()
3032
refresh_lock = Lock(redis=self._redis_server, name='{0}_lock'.format(self._unique_id))

boxsdk/auth/remote_managed_oauth2.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ def __init__(self, retrieve_access_token=None, *args, **kwargs):
1717
:type retrieve_access_token:
1818
`callable` of `unicode` => `unicode`
1919
"""
20+
# pylint:disable=keyword-arg-before-vararg
2021
self._retrieve_access_token = retrieve_access_token
2122
super(RemoteOAuth2Mixin, self).__init__(*args, **kwargs)
2223

boxsdk/network/default_network.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ def request(self, method, url, access_token, **kwargs):
2020
"""Base class override.
2121
Make a network request using a requests.Session.
2222
"""
23+
# pylint:disable=abstract-class-instantiated
2324
return self.network_response_constructor(
2425
request_response=self._session.request(method, url, **kwargs),
2526
access_token_used=access_token,

boxsdk/object/file.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,4 +278,4 @@ def get_shared_link_download_url(
278278
allow_preview=allow_preview,
279279
password=password,
280280
)
281-
return item.shared_link['download_url']
281+
return item.shared_link['download_url'] # pylint:disable=no-member

docs/source/boxsdk.object.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,14 @@ boxsdk.object.metadata module
116116
:undoc-members:
117117
:show-inheritance:
118118

119+
boxsdk.object.recent_item module
120+
--------------------------------
121+
122+
.. automodule:: boxsdk.object.recent_item
123+
:members:
124+
:undoc-members:
125+
:show-inheritance:
126+
119127
boxsdk.object.search module
120128
---------------------------
121129

docs/source/boxsdk.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ Subpackages
1010
boxsdk.client
1111
boxsdk.network
1212
boxsdk.object
13+
boxsdk.pagination
1314
boxsdk.session
1415
boxsdk.util
1516

0 commit comments

Comments
 (0)