mirror of
https://github.com/django/django.git
synced 2025-09-07 19:21:13 +00:00
Refs #23919 -- Removed six.PY2/PY3 usage
Thanks Tim Graham for the review.
This commit is contained in:
parent
e63d98b7be
commit
c716fe8782
111 changed files with 305 additions and 1296 deletions
|
@ -12,7 +12,6 @@ from django.core.exceptions import ImproperlyConfigured
|
|||
from django.db import DEFAULT_DB_ALIAS
|
||||
from django.db.backends.base.base import BaseDatabaseWrapper
|
||||
from django.db.utils import DatabaseError as WrappedDatabaseError
|
||||
from django.utils import six
|
||||
from django.utils.encoding import force_str
|
||||
from django.utils.functional import cached_property
|
||||
from django.utils.safestring import SafeBytes, SafeText
|
||||
|
@ -46,9 +45,6 @@ from .schema import DatabaseSchemaEditor # NOQA isort:skip
|
|||
from .utils import utc_tzinfo_factory # NOQA isort:skip
|
||||
from .version import get_version # NOQA isort:skip
|
||||
|
||||
if six.PY2:
|
||||
psycopg2.extensions.register_type(psycopg2.extensions.UNICODE)
|
||||
psycopg2.extensions.register_type(psycopg2.extensions.UNICODEARRAY)
|
||||
psycopg2.extensions.register_adapter(SafeBytes, psycopg2.extensions.QuotedString)
|
||||
psycopg2.extensions.register_adapter(SafeText, psycopg2.extensions.QuotedString)
|
||||
psycopg2.extras.register_uuid()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue