Commit aebaf0cc authored by Jonathan Schaeffer's avatar Jonathan Schaeffer
Browse files

Extend if we have a short network code

parent a2e5859a
...@@ -127,11 +127,12 @@ def cli(configfile, force_scan, dryrun, verbose): ...@@ -127,11 +127,12 @@ def cli(configfile, force_scan, dryrun, verbose):
for stat in statistics: for stat in statistics:
if re.match('^[1-9XYZ]', stat['network']): if re.match('^[1-9XYZ]', stat['network']):
stat['is_permanent'] = True stat['is_permanent'] = True
try: if len(stat['network']) < 3 :
stat['network'] = extender.extend( try:
stat['network'], int(stat['year'])) stat['network'] = extender.extend(
except ValueError: stat['network'], int(stat['year']))
logger.debug("Network %s exists ?" % stat['network']) except ValueError:
logger.debug("Network %s exists ?" % stat['network'])
else: else:
stat['is_permanent'] = False stat['is_permanent'] = False
stat['date'] = today stat['date'] = today
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment