diff options
author | Ian Clatworthy <ian.clatworthy@canonical.com> | 2009-08-29 15:28:33 +1000 |
---|---|---|
committer | Ian Clatworthy <ian.clatworthy@canonical.com> | 2009-08-29 15:28:33 +1000 |
commit | b4bf1987ebe44067012ffb0a0748a1f782dba38c (patch) | |
tree | bbe058c5392c52f6e3000b6919933b0062b3d745 | |
parent | 83d8431990c9d97e5c0ac299de7dc1853071f0be (diff) | |
download | python-fastimport-b4bf1987ebe44067012ffb0a0748a1f782dba38c.tar.gz |
fix warning messages on non-utf8 names & emails
-rw-r--r-- | parser.py | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -270,7 +270,7 @@ class ImportParser(LineBasedParser): # We auto-detect the date format when a date is first encountered self.date_parser = None - def _warning(self, msg): + def warning(self, msg): sys.stderr.write("warning line %d: %s\n" % (self.lineno, msg)) def iter_commands(self): @@ -353,7 +353,7 @@ class ImportParser(LineBasedParser): try: message = message.decode('utf_8') except UnicodeDecodeError: - self._warning( + self.warning( "commit message not in utf8 - replacing unknown characters") message = message.decode('utf_8', 'replace') from_ = self._get_from() |