Skip to content

Commit 1d380f7

Browse files
committed
fix: Psycopg2 has no wheels on py3.8
1 parent 0a20f09 commit 1d380f7

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

tests/integrations/django/test_basic.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
import platform
2-
31
import pytest
42

53
from werkzeug.test import Client
@@ -208,14 +206,13 @@ def test_sql_dict_query_params(sentry_init, capture_events):
208206
assert crumb["message"] == ("SELECT count(*) FROM people_person WHERE foo = 10")
209207

210208

211-
@pytest.mark.skipif(
212-
platform.python_implementation() == "PyPy", reason="psycopg broken on pypy"
213-
)
214209
@pytest.mark.django_db
215210
def test_sql_psycopg2_string_composition(sentry_init, capture_events):
216211
sentry_init(integrations=[DjangoIntegration()], send_default_pii=True)
217212
from django.db import connection
218-
from psycopg2 import sql as psycopg2_sql
213+
214+
psycopg2 = pytest.importorskip("psycopg2")
215+
psycopg2_sql = psycopg2.sql
219216

220217
sql = connection.cursor()
221218

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ envlist =
4141
deps =
4242
-r test-requirements.txt
4343

44-
py{2.7,3.4,3.5,3.6,3.7,3.8}-django: psycopg2>=2.7.5
44+
py{2.7,3.4,3.5,3.6,3.7}-django: psycopg2>=2.7.5
4545

4646
django-{1.6,1.7,1.8}: pytest-django<3.0
4747
django-{1.9,1.10,1.11,2.0,2.1,dev}: pytest-django>=3.0

0 commit comments

Comments
 (0)