Improve error output.
This commit is contained in:
parent
a5dab10c5d
commit
32a2335821
2
.gitignore
vendored
2
.gitignore
vendored
@ -1,3 +1,5 @@
|
||||
*.log
|
||||
*.pyc
|
||||
/.last_file
|
||||
/export.csv
|
||||
/mosobjects.db3
|
||||
|
@ -37,7 +37,6 @@ msg.attach(att)
|
||||
|
||||
#print(repr(clips))
|
||||
print(msg.as_string())
|
||||
|
||||
p = Popen(["/usr/sbin/sendmail", "-oi", "markus.birth@weltn24.de", "sebastian.erb@weltn24.de"], stdin=PIPE)
|
||||
p.communicate(msg.as_bytes())
|
||||
|
||||
|
@ -68,8 +68,8 @@ for file in files_to_parse:
|
||||
except ET.ParseError as e:
|
||||
print("ERROR parsing {}: {}".format(file, e), file=sys.stderr)
|
||||
break
|
||||
except:
|
||||
print("ERROR processing {}!".format(file), file=sys.stderr)
|
||||
except Exception as e:
|
||||
print("ERROR processing {} - {}!".format(file, e), file=sys.stderr)
|
||||
break
|
||||
|
||||
db.finish()
|
||||
|
Loading…
x
Reference in New Issue
Block a user