forked from orbit-oss/flask
Fix DeprecationWarning on collections import
This commit is contained in:
parent
c9245609f4
commit
e4ebbd3f5b
2 changed files with 4 additions and 2 deletions
|
|
@ -28,6 +28,7 @@ if not PY2:
|
|||
|
||||
from inspect import getfullargspec as getargspec
|
||||
from io import StringIO
|
||||
import collections.abc as collections_abc
|
||||
|
||||
def reraise(tp, value, tb=None):
|
||||
if value.__traceback__ is not tb:
|
||||
|
|
@ -47,6 +48,7 @@ else:
|
|||
|
||||
from inspect import getargspec
|
||||
from cStringIO import StringIO
|
||||
import collections as collections_abc
|
||||
|
||||
exec('def reraise(tp, value, tb=None):\n raise tp, value, tb')
|
||||
|
||||
|
|
|
|||
|
|
@ -11,17 +11,17 @@
|
|||
|
||||
import hashlib
|
||||
import warnings
|
||||
from collections import MutableMapping
|
||||
from datetime import datetime
|
||||
|
||||
from itsdangerous import BadSignature, URLSafeTimedSerializer
|
||||
from werkzeug.datastructures import CallbackDict
|
||||
|
||||
from flask._compat import collections_abc
|
||||
from flask.helpers import is_ip, total_seconds
|
||||
from flask.json.tag import TaggedJSONSerializer
|
||||
|
||||
|
||||
class SessionMixin(MutableMapping):
|
||||
class SessionMixin(collections_abc.MutableMapping):
|
||||
"""Expands a basic dictionary with session attributes."""
|
||||
|
||||
@property
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue