Catch invalid date exceptions, and continue on

svn: r11
This commit is contained in:
Don Allingham committed 2001-05-14 23:51:49 +00:00
1 parent 1c77a167f5
commit 592555d88c
1 file changed
+8 -2
+8 -2
View File
@@ -332,7 +332,10 @@ def importData(database, filename):
regex_match = dateRegexp.match(line)
if regex_match :
matches = regex_match.groups()
event.setDate(matches[0])
try:
event.setDate(matches[0])
except:
pass
continue
regex_match = typeRegexp.match(line)
@@ -530,7 +533,10 @@ def importData(database, filename):
regex_match = dateRegexp.match(line)
if regex_match :
matches = regex_match.groups()
event.setDate(matches[0])
try:
event.setDate(matches[0])
except:
pass
continue
regex_match = fileRegexp.match(line)