eric7/EricNetwork/EricTldExtractor.py

branch
eric7
changeset 9152
8a68afaf1ba2
parent 8881
54e42bc2437a
child 9162
8b75b1668583
--- a/eric7/EricNetwork/EricTldExtractor.py	Wed Jun 15 09:44:07 2022 +0200
+++ b/eric7/EricNetwork/EricTldExtractor.py	Thu Jun 16 18:28:59 2022 +0200
@@ -16,7 +16,7 @@
 import os
 import re
 
-from PyQt6.QtCore import QObject, QUrl, QFile, QFileInfo, QIODevice, qWarning
+from PyQt6.QtCore import QObject, QUrl, QFile, QIODevice, qWarning
 
 from EricWidgets import EricMessageBox
 
@@ -271,11 +271,11 @@
         dataFileName = ""
         parsedDataFileExist = False
         
-        for path in self.__dataSearchPaths:
-            dataFileName = (
-                QFileInfo(path + "/effective_tld_names.dat").absoluteFilePath()
+        for searchPath in self.__dataSearchPaths:
+            dataFileName = os.path.abspath(
+                os.path.join(searchPath, "effective_tld_names.dat")
             )
-            if QFileInfo(dataFileName).exists():
+            if os.path.exists(dataFileName):
                 parsedDataFileExist = True
                 break
         
@@ -453,10 +453,10 @@
         testDataFileExist = False
         
         for path in self.__dataSearchPaths:
-            testDataFileName = (
-                QFileInfo(path + "/test_psl.txt").absoluteFilePath()
+            testDataFileName = os.path.abspath(
+                os.path.join(path, "test_psl.txt")
             )
-            if QFileInfo(testDataFileName).exists():
+            if os.path.exists(testDataFileName):
                 testDataFileExist = True
                 break
         

eric ide

mercurial