Everleaf: Make re_GameInfo error handling consistant with other sites.
When re_GameInfo fails to match now, the first 100 characters of the hand will be printed to the log. Makes it much easier to identify the offending hands. Error now also throws an FpdbParseError for the importing process to catch
This commit is contained in:
parent
7721468c92
commit
bc59e12768
|
@ -106,7 +106,10 @@ or None if we fail to get the info """
|
|||
|
||||
m = self.re_GameInfo.search(handText)
|
||||
if not m:
|
||||
return None
|
||||
tmp = handText[0:100]
|
||||
log.error(_("determineGameType: Unable to recognise gametype from: '%s'") % tmp)
|
||||
log.error(_("determineGameType: Raising FpdbParseError"))
|
||||
raise FpdbParseError(_("Unable to recognise gametype from: '%s'") % tmp)
|
||||
|
||||
mg = m.groupdict()
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user