Mercurial > cpython-lru_cache-weakref
diff Lib/sqlite3/dbapi2.py @ 82403:eb45fd74db34 2.7
Issue #14720: Enhance sqlite3 microsecond conversion, document its behavior
| author | Petri Lehtinen <petri@digip.org> |
|---|---|
| date | Tue, 26 Feb 2013 21:32:02 +0200 |
| parents | 6911df35b7b6 |
| children |
line wrap: on
line diff
--- a/Lib/sqlite3/dbapi2.py Tue Feb 26 12:37:07 2013 +0000 +++ b/Lib/sqlite3/dbapi2.py Tue Feb 26 21:32:02 2013 +0200 @@ -1,4 +1,4 @@ -#-*- coding: ISO-8859-1 -*- +# -*- coding: iso-8859-1 -*- # pysqlite2/dbapi2.py: the DB-API 2.0 interface # # Copyright (C) 2004-2005 Gerhard Häring <gh@ghaering.de> @@ -68,7 +68,7 @@ timepart_full = timepart.split(".") hours, minutes, seconds = map(int, timepart_full[0].split(":")) if len(timepart_full) == 2: - microseconds = int('{:0<6}'.format(timepart_full[1].decode())) + microseconds = int('{:0<6.6}'.format(timepart_full[1].decode())) else: microseconds = 0
