Traceback (most recent call last):
File "test.py", line 116, in <module>
clean = filter(None, re.match(r'^(\S+) (.*?) (\S+)$', full).groups())
AttributeError: 'NoneType' object has no attribute 'groups'
, : AttributeError
:
try:
clean = filter(None, re.match(r'^(\S+) (.*?) (\S+)$', full).groups())
except AttributeError:
clean = ""
my_match = re.match(r'^(\S+) (.*?) (\S+)$', full)
my_match = ''
if my_match is not None:
clean = my_match.groups()