From eda381e437b7ca5b1c415b88c207b572c89d6d4b Mon Sep 17 00:00:00 2001 From: Tomas Raila Date: Thu, 25 Jan 2018 11:35:09 +0200 Subject: [PATCH] Cast filepath to python string --- labelImg.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/labelImg.py b/labelImg.py index 50d31c0d..735bf72f 100755 --- a/labelImg.py +++ b/labelImg.py @@ -888,6 +888,9 @@ class MainWindow(QMainWindow, WindowMixin): if filePath is None: filePath = self.settings.get(SETTING_FILENAME) + # Make sure that filePath is a regular python string, rather than QString + filePath = str(filePath) + unicodeFilePath = ustr(filePath) # Tzutalin 20160906 : Add file list and dock to move faster # Highlight the file item