over() clause would be an itertools.chain() and
not a list, causing "can only concatenate list"
TypeError when combined with other clauses.
will be coerced to integer. [ticket:2116]
(also in 0.6.7)
+ - fixed bug where "from" clause gathering from an
+ over() clause would be an itertools.chain() and
+ not a list, causing "can only concatenate list"
+ TypeError when combined with other clauses.
+
- engine
- The C extension is now enabled by default on CPython
2.x with a fallback to pure python if it fails to
@property
def _from_objects(self):
- return itertools.chain(
+ return list(itertools.chain(
*[c._from_objects for c in
(self.func, self.partition_by, self.order_by)
if c is not None]
- )
+ ))
class _Label(ColumnElement):
"""Represents a column label (AS).
"AS anon_1 FROM mytable"
)
+ # this tests that _from_objects
+ # concantenates OK
+ self.assert_compile(
+ select([column("x") + over(func.foo())]),
+ "SELECT x + foo() OVER () AS anon_1"
+ )
def test_date_between(self):