diff --git a/CHANGES.md b/CHANGES.md index e60e7b34..dd751c0f 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,4 +1,10 @@ -### 3.27.1 (2023-02-10 15:25:00 UTC) +### 3.27.2 (2023-02-10 19:25:00 UTC) + +* Fix revert update +* Fix installations that don't have previously saved cleanup lock files + + +### 3.27.1 (2023-02-10 15:25:00 UTC) * Change display show status in Change show header * Fix TMDB language caching diff --git a/_cleaner.py b/_cleaner.py index 9b97bd7d..bfc31345 100644 --- a/_cleaner.py +++ b/_cleaner.py @@ -91,12 +91,6 @@ cleanups = [ r'lib\tvmaze_api\__pycache__', r'lib\tvmaze_api']], ['.cleaned006.tmp', r'lib\boto', [ r'lib\boto', r'lib\growl', - r'lib\hachoir\core', r'lib\hachoir\field', r'lib\hachoir\metadata', - r'lib\hachoir\parser\archive', r'lib\hachoir\parser\audio', - r'lib\hachoir\parser\common', r'lib\hachoir\parser\container', - r'lib\hachoir\parser\image', r'lib\hachoir\parser\misc', - r'lib\hachoir\parser\network', r'lib\hachoir\parser\program', - r'lib\hachoir\parser\video', r'lib\hachoir\parser', r'lib\hachoir\stream', r'lib\httplib2\lib\oauth2\lib\pythontwitter\lib\tmdb_api']], ['.cleaned004.tmp', r'lib\requests\packages', [ r'lib\requests\packages', r'lib\pynma']], diff --git a/sickgear/version_checker.py b/sickgear/version_checker.py index 3298b973..a2c892a2 100644 --- a/sickgear/version_checker.py +++ b/sickgear/version_checker.py @@ -566,8 +566,11 @@ class GitUpdateManager(UpdateManager): '%s/%s' % (sickgear.GIT_REMOTE, self._old_branch)]) if 0 != exit_status: return exit_status - _, _, exit_status = self._run_git(['reset', '--hard', '"%s"' % self._old_commit_hash]) + _, _, exit_status = self._run_git(['reset', '--hard', '%s' % self._old_commit_hash]) if 0 == exit_status: + self.branch = self._old_branch + sickgear.BRANCH = self.branch + self._cur_commit_hash = self._old_commit_hash self._old_commit_hash = None self._old_branch = None return exit_status @@ -579,6 +582,9 @@ class GitUpdateManager(UpdateManager): on the call's success. """ + self._old_branch = self._find_installed_branch() + self._old_commit_hash = self._cur_commit_hash + if self.branch == self._find_installed_branch(): if not self._cur_pr_number: _, _, exit_status = self._run_git(['pull', '-f', '%s' % sickgear.GIT_REMOTE, '%s' % self.branch])