[medusa] Medusa, Python 2.0.

Fredrik Lundh fredrik@p...
Sat, 28 Apr 2001 11:00:54 +0200


Johannes Grødem wrote:
> Seems Medusa doesn't quite like Python 2.0. Some library incompatibilities.
> The auth-handler, for example, excepts re-expressions to have a
> group-function, which it did, in 1.5.2, but not anymore.

there has never been a group function in the re module. there's
a group *method* on match objects, but it's still there in 2.0.

Cheers /F

Python 1.5.2 (#0, May 9 2000, 14:04:03)
>>> import re
>>> re.group()
Traceback (innermost last):
File "<stdin>", line 1, in ?
AttributeError: group
>>> p = re.compile("x")
>>> p.group()
Traceback (innermost last):
File "<stdin>", line 1, in ?
AttributeError: group
>>> m = p.match("x")
>>> m.group()
'x'

Python 2.0 (#8, Jan 4 2001, 12:33:41)
>>> import re
>>> re.group
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: group
>>> p = re.compile("x")
>>> p.group()
Traceback (most recent call last):
File "<stdin>", line 1, in ?
AttributeError: group
>>> m = p.match("x")
>>> m.group()
'x'