From eef0b92374233f67621f56feda3147aa9ccab069 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Mon, 29 Oct 2018 21:06:11 +1000 Subject: [PATCH] correctly load prefs file modified in more recent qt --- aqt/profiles.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/aqt/profiles.py b/aqt/profiles.py index d2537a31d..054fe1784 100644 --- a/aqt/profiles.py +++ b/aqt/profiles.py @@ -133,6 +133,12 @@ a flash drive.""" % self.base) def _unpickle(self, data): class Unpickler(pickle.Unpickler): def find_class(self, module, name): + if module == "PyQt5.sip": + try: + import PyQt5.sip + except: + # use old sip location + module = "sip" fn = super().find_class(module, name) if module == "sip" and name == "_unpickle_type": def wrapper(mod, obj, args):