On Sat, 14 Nov 2009 16:28:36 +0100, Michele Petrazzo - Unipex <[email protected]> wrote: > Hi, > just discovered that pylupdate4 has a problem with empty docstring. If I > forgot to write at least one character inside the docstring space, > pylupdate4 stops to look for new string translation. > > class Main(Qtclass): > def __init__(self): > """""" > > def test(self): > """simple docstring""" > return self.trUtf8("test") > > generate: > > pylupdate4: main.py:9: Unterminated string > pylupdate4: Updating 'i18n/i18nit.ts'... > pylupdate4: Found 0 source texts (0 new and 0 already existing) > > adding a simgle char ("a") to the first docstring: > > pylupdate4: Updating 'i18n/i18nit.ts'... > pylupdate4: Found 1 source text (1 new and 0 already existing)
Fixing this properly is very risky as the parsing code isn't the greatest in the world. Instead I've clarified the error message. One day I'll get round to a Python version of pylupdate which uses the interpreter to do the parsing. Thanks, Phil _______________________________________________ PyQt mailing list [email protected] http://www.riverbankcomputing.com/mailman/listinfo/pyqt
