File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change 5
5
6
6
from contextlib import contextmanager
7
7
from datetime import datetime
8
- from collections import Mapping , Sequence
9
8
10
9
from sentry_sdk ._compat import (
11
10
urlparse ,
14
13
string_types ,
15
14
number_types ,
16
15
int_types ,
16
+ PY2 ,
17
17
)
18
18
19
+ if PY2 :
20
+ # Importing ABCs from collections is deprecated, and will stop working in 3.8
21
+ # https://github.com/python/cpython/blob/master/Lib/collections/__init__.py#L49
22
+ from collections import Mapping , Sequence
23
+ else :
24
+ # New in 3.3
25
+ # https://docs.python.org/3/library/collections.abc.html
26
+ from collections .abc import Mapping , Sequence
19
27
20
28
epoch = datetime (1970 , 1 , 1 )
21
29
22
30
23
- # The logger is created here but initializde in the debug support module
31
+ # The logger is created here but initialized in the debug support module
24
32
logger = logging .getLogger ("sentry_sdk.errors" )
25
33
26
34
You can’t perform that action at this time.
0 commit comments