Entry
I'm getting an error stating that "None" object has no attribute "groups" during setup of numpy, any ideas?
Oct 30th, 2000 02:30
mm mm, Michael Risser, Oleg Broytmann
It seems you are trying to do the following - match or search for
regular expression:
match_object = re.search(pattern, string)
groups = match_object.groups()
But your regexp didn't match anything in the string, so match_object
here is really None. Test it before doing anything with it:
match_object = re.search(pattern, string)
if match_object:
groups = match_object.groups()
else:
print "No match!"