From 3126611ecf4968d7bbecbc98487377c8f9c04f7c Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Mon, 29 Oct 2018 21:06:33 +1000 Subject: [PATCH] display warning when profile corrupted --- aqt/profiles.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/aqt/profiles.py b/aqt/profiles.py index 054fe1784..73e5d8931 100644 --- a/aqt/profiles.py +++ b/aqt/profiles.py @@ -162,6 +162,11 @@ a flash drive.""" % self.base) try: self.profile = self._unpickle(data) except: + QMessageBox.warning( + None, _("Profile Corrupt"), _("""\ +Anki could not read your profile data. Window sizes and your sync login \ +details have been forgotten.""")) + print("resetting corrupt profile") self.profile = profileConf.copy() self.save()