Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Imported reduce from functools for forward compatibility.

In Python 3, reduce has to be imported from functools.
  • Loading branch information...
commit 35e65855680be2c8a495ec926c7eaf992c79edc0 1 parent 4b58e94
@claudep claudep authored
View
1  django/contrib/admin/views/main.py
@@ -1,4 +1,5 @@
import operator
+from functools import reduce
from django.core.exceptions import SuspiciousOperation, ImproperlyConfigured
from django.core.paginator import InvalidPage
View
1  django/core/exceptions.py
@@ -1,6 +1,7 @@
"""
Global Django exception and warning classes.
"""
+from functools import reduce
class DjangoRuntimeWarning(RuntimeWarning):
pass
View
1  django/utils/crypto.py
@@ -8,6 +8,7 @@
import binascii
import operator
import time
+from functools import reduce
# Use the system PRNG if possible
import random
Please sign in to comment.
Something went wrong with that request. Please try again.