Skip to content

Commit 3be1cf5

Browse files
authored
Merge pull request #137 from pusher/collections_abc
Import Abstract Base Classes from collections.abc in newer Python versions
2 parents 67ee733 + b675e38 commit 3be1cf5

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

pusher/pusher_client.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,12 @@
66
absolute_import,
77
division)
88

9-
import collections
9+
import sys
10+
# Abstract Base Classes were moved into collections.abc in Python 3.3
11+
if sys.version_info >= (3,3):
12+
import collections.abc as collections
13+
else:
14+
import collections
1015
import hashlib
1116
import os
1217
import re

0 commit comments

Comments
 (0)