Skip to content

Commit

Permalink
Merge pull request #187 from davvid/deprecations
Browse files Browse the repository at this point in the history
PR: Avoid deprecated "from collections import MutableMapping"
  • Loading branch information
ccordoba12 authored May 4, 2019
2 parents 137fd8c + 059b26e commit ca95bb8
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions qtpy/py3compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,9 @@
import sys
import os

PY2 = sys.version[0] == '2'
PY3 = sys.version[0] == '3'
PY2 = sys.version_info[0] == 2
PY3 = sys.version_info[0] == 3
PY33 = PY3 and sys.version_info[1] >= 3


# =============================================================================
Expand Down Expand Up @@ -73,7 +74,10 @@
from sys import maxsize
import io
import pickle
from collections import MutableMapping
if PY33:
from collections.abc import MutableMapping
else:
from collections import MutableMapping
import _thread
import reprlib

Expand Down

0 comments on commit ca95bb8

Please sign in to comment.