Skip to content

Commit b15e5d3

Browse files
authored
Merge pull request readthedocs#4792 from rtfd/humitos/pur/update
All package updates
2 parents a5a761b + b774e08 commit b15e5d3

File tree

10 files changed

+67
-73
lines changed

10 files changed

+67
-73
lines changed

readthedocs/projects/constants.py

+12-12
Original file line numberDiff line numberDiff line change
@@ -314,24 +314,24 @@
314314

315315
LOG_TEMPLATE = '(Build) [{project}:{version}] {msg}'
316316

317-
PROJECT_PK_REGEX = '(?:[-\w]+)'
318-
PROJECT_SLUG_REGEX = '(?:[-\w]+)'
317+
PROJECT_PK_REGEX = r'(?:[-\w]+)'
318+
PROJECT_SLUG_REGEX = r'(?:[-\w]+)'
319319

320320
GITHUB_REGEXS = [
321-
re.compile('github.com/(.+)/(.+)(?:\.git){1}$'),
322-
re.compile('github.com/(.+)/(.+)'),
323-
re.compile('github.com:(.+)/(.+)\.git$'),
321+
re.compile(r'github.com/(.+)/(.+)(?:\.git){1}$'),
322+
re.compile(r'github.com/(.+)/(.+)'),
323+
re.compile(r'github.com:(.+)/(.+)\.git$'),
324324
]
325325
BITBUCKET_REGEXS = [
326-
re.compile('bitbucket.org/(.+)/(.+)\.git$'),
327-
re.compile('@bitbucket.org/(.+)/(.+)\.git$'),
328-
re.compile('bitbucket.org/(.+)/(.+)/?'),
329-
re.compile('bitbucket.org:(.+)/(.+)\.git$'),
326+
re.compile(r'bitbucket.org/(.+)/(.+)\.git$'),
327+
re.compile(r'@bitbucket.org/(.+)/(.+)\.git$'),
328+
re.compile(r'bitbucket.org/(.+)/(.+)/?'),
329+
re.compile(r'bitbucket.org:(.+)/(.+)\.git$'),
330330
]
331331
GITLAB_REGEXS = [
332-
re.compile('gitlab.com/(.+)/(.+)(?:\.git){1}$'),
333-
re.compile('gitlab.com/(.+)/(.+)'),
334-
re.compile('gitlab.com:(.+)/(.+)\.git$'),
332+
re.compile(r'gitlab.com/(.+)/(.+)(?:\.git){1}$'),
333+
re.compile(r'gitlab.com/(.+)/(.+)'),
334+
re.compile(r'gitlab.com:(.+)/(.+)\.git$'),
335335
]
336336
GITHUB_URL = (
337337
'https://github.com/{user}/{repo}/'

readthedocs/restapi/views/integrations.py

+5-1
Original file line numberDiff line numberDiff line change
@@ -434,4 +434,8 @@ def post(self, request, project_slug, integration_pk):
434434
)
435435
view_cls = self.VIEW_MAP[integration.integration_type]
436436
view = view_cls.as_view(integration=integration)
437-
return view(request, project_slug)
437+
# DRF uses ``rest_framework.request.Request`` and Django expects
438+
# ``django.http.HttpRequest``
439+
# https://www.django-rest-framework.org/api-guide/requests/
440+
# https://github.com/encode/django-rest-framework/pull/5771#issuecomment-362815342
441+
return view(request._request, project_slug)

readthedocs/restapi/views/model_views.py

+6-3
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,8 @@ class ProjectViewSet(UserSelectViewSet):
9292
admin_serializer_class = ProjectAdminSerializer
9393
model = Project
9494
pagination_class = api_utils.ProjectPagination
95-
filter_fields = ('slug',)
95+
filter_fields = ('slug',) # django-filter<2.0.0
96+
filterset_fields = ('slug',)
9697

9798
@decorators.detail_route()
9899
def valid_versions(self, request, **kwargs):
@@ -234,7 +235,8 @@ class VersionViewSet(UserSelectViewSet):
234235
serializer_class = VersionSerializer
235236
admin_serializer_class = VersionAdminSerializer
236237
model = Version
237-
filter_fields = ('active', 'project__slug',)
238+
filter_fields = ('active', 'project__slug',) # django-filter<2.0.0
239+
filterset_fields = ('active', 'project__slug',)
238240

239241

240242
class BuildViewSetBase(UserSelectViewSet):
@@ -243,7 +245,8 @@ class BuildViewSetBase(UserSelectViewSet):
243245
serializer_class = BuildSerializer
244246
admin_serializer_class = BuildAdminSerializer
245247
model = Build
246-
filter_fields = ('project__slug', 'commit')
248+
filter_fields = ('project__slug', 'commit') # django-filter<2.0.0
249+
filterset_fields = ('project__slug', 'commit')
247250

248251

249252
class BuildViewSet(SettingsOverrideObject):

readthedocs/search/utils.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ def parse_path_from_file(file_path):
103103
# "path/index.html" => "path/index"
104104
# "/path/index" => "path/index"
105105
path = re.sub('/$', '/index', path)
106-
path = re.sub('\.html$', '', path)
106+
path = re.sub(r'\.html$', '', path)
107107
path = re.sub('^/', '', path)
108108

109109
return path

readthedocs/settings/base.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -296,8 +296,8 @@ def USE_PROMOS(self): # noqa
296296

297297
# CORS
298298
CORS_ORIGIN_REGEX_WHITELIST = (
299-
'^http://(.+)\.readthedocs\.io$',
300-
'^https://(.+)\.readthedocs\.io$'
299+
r'^http://(.+)\.readthedocs\.io$',
300+
r'^https://(.+)\.readthedocs\.io$',
301301
)
302302
# So people can post to their accounts
303303
CORS_ALLOW_CREDENTIALS = True

requirements/deploy.txt

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
-r pip.txt
22
# http://initd.org/psycopg/docs/install.html#binary-install-from-pypi
3-
psycopg2==2.7.5 --no-binary psycopg2
3+
psycopg2==2.7.6.1 --no-binary psycopg2
44
gunicorn==19.9.0
5-
pysolr==3.7.0
6-
django-redis-cache==1.7.1
5+
django-redis-cache==1.8.1
76

87
#For resizing images
98
pillow

requirements/docs-lint.txt

+2-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,2 @@
1-
# Sphinx 1.8 is incompatible with
2-
# the latest version of rstcheck
3-
Sphinx<1.8
4-
rstcheck==3.3
1+
Sphinx==1.8.2
2+
rstcheck==3.3.1

requirements/lint.txt

+3-6
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,12 @@
11
-r pip.txt
2-
# We need these special cases of Python < 3 for Read the Docs
3-
# corporate site.
2+
# We need these special cases of Python < 3 because we run tests with
3+
# Python 2 still
44
astroid==2.0.4; python_version > '3'
55
astroid==1.6.4; python_version < '3'
6-
76
pylint==2.1.1; python_version > '3'
87
pylint<2; python_version < '3'
9-
108
pylint-django==2.0.2; python_version > '3'
119
pylint-django==0.11.1; python_version < '3'
12-
1310
pylint-celery==0.3
14-
prospector==1.1.2
11+
prospector==1.1.6.2
1512
pyflakes==2.0.0

requirements/pip.txt

+29-36
Original file line numberDiff line numberDiff line change
@@ -1,65 +1,59 @@
11
# Base packages
2-
pip==18.0
2+
pip==18.1
33
appdirs==1.4.3
4-
virtualenv==16.0.0
4+
virtualenv==16.1.0
55
docutils==0.14
6-
Sphinx==1.7.8
7-
sphinx_rtd_theme==0.4.1
8-
sphinx-tabs==1.1.7
6+
Sphinx==1.8.2
7+
sphinx_rtd_theme==0.4.2
8+
sphinx-tabs==1.1.10
99
# Required to avoid Transifex error with reserved slug
1010
# https://github.com/sphinx-doc/sphinx-intl/pull/27
1111
git+https://github.com/agjohnson/sphinx-intl.git@7b5c66bdb30f872b3b1286e371f569c8dcb66de5#egg=sphinx-intl
1212

13-
Pygments==2.2.0
13+
Pygments==2.3.0
1414

15-
mkdocs==0.17.3
16-
# mkdocs requires markdown
17-
# Markdown 3.0 breaks with older Django Rest Framework
18-
Markdown<3.0
15+
mkdocs==1.0.4
16+
Markdown==3.0.1
1917

2018
django==1.11.16
2119
six==1.11.0
22-
future==0.16.0
23-
24-
# django-tastypie 0.14.0 drops support for django 1.9
25-
django-tastypie==0.13.3
26-
20+
future==0.17.1
21+
django-tastypie==0.14.2
2722
django-guardian==1.4.9
28-
django-extensions==2.1.2
23+
django-extensions==2.1.4
2924

30-
# djangorestframework 3.7.x drops support for django 1.9.x
31-
djangorestframework==3.6.4
25+
djangorestframework==3.9.0
3226

3327
# Filtering for the REST API
34-
# django-filter>2.0 require Django 1.11
35-
# https://django-filter.readthedocs.io/en/master/guide/migration.html#migrating-to-2-0
36-
# Besides the guide, check this comment for the migration
37-
# https://github.com/rtfd/readthedocs.org/pull/4318#discussion_r214163531
38-
django-filter==1.1.0
28+
# When Python2 gets deprecated we can upgrade django-filter
29+
# > from .filterset import FilterSet
30+
# E File "/home/travis/build/rtfd/readthedocs.org/.tox/py27/lib/python2.7/site-packages/django_filters/filterset.py", line 184
31+
# E def __init__(self, data=None, queryset=None, *, request=None, prefix=None):
32+
# E ^
33+
# E SyntaxError: invalid syntax
34+
django-filter<2.0.0
3935

4036
django-vanilla-views==1.0.5
4137
jsonfield==2.0.2
4238

43-
requests==2.19.1
39+
requests==2.20.1
4440
requests-toolbelt==0.8.0
4541
slumber==0.7.1
46-
lxml==4.2.4
42+
lxml==4.2.5
4743
defusedxml==0.5.0
4844

4945
# Basic tools
50-
redis==2.10.6
46+
redis==3.0.1
5147
# Celery 4.2 is incompatible with our code
5248
# when ALWAYS_EAGER = True
5349
celery==4.1.1
5450

55-
# django-allauth 0.33.0 dropped support for Django 1.9
56-
# https://django-allauth.readthedocs.io/en/latest/release-notes.html#backwards-incompatible-changes
57-
django-allauth==0.32.0
51+
django-allauth==0.38.0
5852

5953
dnspython==1.15.0
6054

6155
# VCS
62-
httplib2==0.11.3
56+
httplib2==0.12.0
6357

6458
# GitPython 2.1.11 makes TestGitBackend.test_git_tags to fail because
6559
# of an UnicodeError
@@ -77,12 +71,12 @@ pyquery==1.4.0
7771

7872
# Utils
7973
django-gravatar2==1.4.2
80-
pytz==2018.5
74+
pytz==2018.7
8175
beautifulsoup4==4.6.3
8276
Unipath==1.1
8377
django-kombu==0.9.4
8478
mock==2.0.0
85-
stripe==2.12.0
79+
stripe==2.13.0
8680

8781
django-formtools==2.1
8882

@@ -96,9 +90,8 @@ django-textclassifier==1.0
9690
django-annoying==0.10.4
9791
django-messages-extends==0.6.0
9892
djangorestframework-jsonp==1.0.2
99-
# django-taggit 0.23.0 drops support for django < 1.11
100-
django-taggit==0.22.0
101-
dj-pagination==2.3.2
93+
django-taggit==0.23.0
94+
dj-pagination==2.4.0
10295

10396
# Docs
10497
sphinxcontrib-httpdomain==1.7.0
@@ -110,7 +103,7 @@ commonmark==0.5.5
110103
recommonmark==0.4.0
111104

112105
# Version comparison stuff
113-
packaging==17.1
106+
packaging==18.0
114107

115108
# Commenting stuff
116109
django-cors-middleware==1.3.1

requirements/testing.txt

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
-r pip.txt
22

33
django-dynamic-fixture==2.0.0
4-
pytest==3.7.4
5-
pytest-django==3.4.2
6-
pytest-xdist==1.23.0
4+
pytest==4.0.1
5+
pytest-django==3.4.4
6+
pytest-xdist==1.24.1
77
pytest-cov
88
apipkg==1.5
99
execnet==1.5.0
@@ -16,9 +16,9 @@ execnet==1.5.0
1616
# (Pinned to 4.4.2 since what we need for testing is still useful)
1717
Mercurial==4.4.2
1818

19-
yamale==1.7.0
19+
yamale==1.8.0
2020
pytest-mock==1.10.0
2121

2222
# local debugging tools
2323
datadiff
24-
ipdb
24+
ipdb

0 commit comments

Comments
 (0)