Skip to content

Commit 0be96f0

Browse files
authored
fix(ci): Fix py3.5-celery and *-django-dev (#990)
Reacting to upstream changes in our dependencies
1 parent 4f8facc commit 0be96f0

File tree

3 files changed

+12
-8
lines changed

3 files changed

+12
-8
lines changed

test-requirements.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,5 @@ mock # for testing under python < 3.3
1010

1111
gevent
1212

13-
newrelic
1413
executing
1514
asttokens

tests/integrations/django/test_transactions.py

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,22 @@
33
import pytest
44
import django
55

6-
try:
6+
if django.VERSION >= (2, 0):
7+
# TODO: once we stop supporting django < 2, use the real name of this
8+
# function (re_path)
9+
from django.urls import re_path as url
10+
from django.conf.urls import include
11+
else:
712
from django.conf.urls import url, include
8-
except ImportError:
9-
# for Django version less than 1.4
10-
from django.conf.urls.defaults import url, include # NOQA
11-
12-
from sentry_sdk.integrations.django.transactions import RavenResolver
13-
1413

1514
if django.VERSION < (1, 9):
1615
included_url_conf = (url(r"^foo/bar/(?P<param>[\w]+)", lambda x: ""),), "", ""
1716
else:
1817
included_url_conf = ((url(r"^foo/bar/(?P<param>[\w]+)", lambda x: ""),), "")
1918

19+
from sentry_sdk.integrations.django.transactions import RavenResolver
20+
21+
2022
example_url_conf = (
2123
url(r"^api/(?P<project_id>[\w_-]+)/store/$", lambda x: ""),
2224
url(r"^api/(?P<version>(v1|v2))/author/$", lambda x: ""),

tox.ini

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,9 @@ deps =
152152
celery-4.4: Celery>=4.4,<4.5,!=4.4.4
153153
celery-5.0: Celery>=5.0,<5.1
154154

155+
py3.5-celery: newrelic<6.0.0
156+
{pypy,py2.7,py3.6,py3.7,py3.8,py3.9}-celery: newrelic
157+
155158
requests: requests>=2.0
156159

157160
aws_lambda: boto3

0 commit comments

Comments
 (0)