return appropriate tuple from import_fpdb_file on file error
This commit is contained in:
parent
560cb1a543
commit
c7541d9f14
|
@ -190,7 +190,8 @@ class Importer:
|
||||||
self.addImportDirectory(dir, True, self.addToDirList[dir][0], self.addToDirList[dir][1])
|
self.addImportDirectory(dir, True, self.addToDirList[dir][0], self.addToDirList[dir][1])
|
||||||
|
|
||||||
for file in self.removeFromFileList:
|
for file in self.removeFromFileList:
|
||||||
del self.filelist[file]
|
if file in self.filelist:
|
||||||
|
del self.filelist[file]
|
||||||
|
|
||||||
self.addToDirList = {}
|
self.addToDirList = {}
|
||||||
self.removeFromFileList = {}
|
self.removeFromFileList = {}
|
||||||
|
@ -243,8 +244,8 @@ class Importer:
|
||||||
if os.path.exists(file):
|
if os.path.exists(file):
|
||||||
inputFile = open(file, "rU")
|
inputFile = open(file, "rU")
|
||||||
else:
|
else:
|
||||||
self.removeFromFileList['file'] = True
|
self.removeFromFileList[file] = True
|
||||||
return
|
return (0, 0, 0, 1, 0)
|
||||||
try:
|
try:
|
||||||
loc = self.pos_in_file[file]
|
loc = self.pos_in_file[file]
|
||||||
except:
|
except:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user