Typo time of the month ;)
I had noticed this some time ago but never bothered to dig into it.
Demo:
>>> from qp.lib.spec import require, identfier_pattern
>>> require('', identifier_pattern)
Traceback (most recent call last):
File "", line 1, in ?
File
"/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-
packages/qp/lib/spec.py", line 159, in require
raise TypeError(error)
TypeError:
Expected: ''
Got:
The error message always seemed strange, but doublecrossed eyes is
normal with hours of abuse, so it is easy to overlook... has anyone not
noticed this before ??
Anyhow, that error is produced in spec.require() with:
format_expected_got(spec, value)
that is defined as:
def format_expected_got(value, spec):
return ('\n Expected: %s\n'
' Got: %r\n') % (format_spec(spec), value)
So, ya, thankfully my eyes are not totally doublecrossed as yet.