diff --git a/ChangeLog b/ChangeLog index ac103d21..9e3e4511 100644 --- a/ChangeLog +++ b/ChangeLog @@ -6,6 +6,8 @@ * psycopg/microprotocols.c: small optimizations. + * Avoid pointless string manipulation in NamedTupleCursor (ticket #10) + 2010-11-08 Daniele Varrazzo * psycopg/microprotocols.c: use faster function to build tuples. diff --git a/lib/extras.py b/lib/extras.py index 47dcbb23..d19c5601 100644 --- a/lib/extras.py +++ b/lib/extras.py @@ -285,8 +285,7 @@ class NamedTupleCursor(_cursor): raise self._exc else: def _make_nt(self, namedtuple=namedtuple): - return namedtuple("Record", - " ".join([d[0] for d in self.description])) + return namedtuple("Record", [d[0] for d in self.description]) class LoggingConnection(_connection):