# HG changeset patch # User Sylvain Thénault # Date 1264167668 -3600 # Node ID 1314772c11830b3281d09e153832cf466d64e4ba # Parent dda74c345b06a5171aecd536ca58fa359754c250# Parent 659ca14ab3566e17f4e5de382bf8a6a1238fef65 backport stable diff -r dda74c345b06 -r 1314772c1183 doc/book/en/annexes/depends.rst --- a/doc/book/en/annexes/depends.rst Fri Jan 22 14:40:29 2010 +0100 +++ b/doc/book/en/annexes/depends.rst Fri Jan 22 14:41:08 2010 +0100 @@ -42,26 +42,31 @@ * indexer - http://www.logilab.org/project/indexer - http://pypi.python.org/pypi/indexer - included in the forest -To activate Sparql querying: - -* fyzz - http://www.logilab.org/project/fyzz - http://pypi.python.org/pypi/fyzz - - included in the forest - To use network communication between cubicweb instances / clients: * Pyro - http://pyro.sourceforge.net/ - http://pypi.python.org/pypi/Pyro If you're using a Postgres database (recommended): + * psycopg2 - http://initd.org/projects/psycopg2 - http://pypi.python.org/pypi/psycopg2 +* plpythonu extension +* tsearch2 extension (for postgres < 8.3, in postgres-contrib) + +Other optional packages : + +: + +* fyzz - http://www.logilab.org/project/fyzz - + http://pypi.python.org/pypi/fyzz - included in the forest, *to activate Sparql querying* For the google-appengine extension to be available, you also need: -* dateutil - http://labix.org/python-dateutil - - http://pypi.python.org/pypi/python-dateutil/ +* vobject - http://vobject.skyhouseconsulting.com/ - + http://pypi.python.org/pypi/vobject, *for the icalendar view*. For those not + benefiting from a packaging system, note that vobject itself depends on + dateutil - http://labix.org/python-dateutil - + http://pypi.python.org/pypi/python-dateutil/. -* vobject - http://vobject.skyhouseconsulting.com/ - - http://pypi.python.org/pypi/vobject - Any help with the packaging of CubicWeb for more than Debian/Ubuntu (including eggs, buildouts, etc) will be greatly appreciated. diff -r dda74c345b06 -r 1314772c1183 rqlrewrite.py --- a/rqlrewrite.py Fri Jan 22 14:40:29 2010 +0100 +++ b/rqlrewrite.py Fri Jan 22 14:41:08 2010 +0100 @@ -327,7 +327,7 @@ self.compute_solutions() except Unsupported: # some solutions have been lost, can't apply this rql expr - self.select.remove_subquery(new, undefine=True) + self.select.remove_subquery(self.select.with_[-1]) raise return subselect diff -r dda74c345b06 -r 1314772c1183 utils.py --- a/utils.py Fri Jan 22 14:40:29 2010 +0100 +++ b/utils.py Fri Jan 22 14:41:08 2010 +0100 @@ -152,6 +152,9 @@ # use networkX instead ? # http://networkx.lanl.gov/reference/algorithms.traversal.html#module-networkx.algorithms.traversal.astar def transitive_closure_of(entity, relname, _seen=None): + """return transitive closure *for the subgraph starting from the given + entity* (eg 'parent' entities are not included in the results) + """ if _seen is None: _seen = set() _seen.add(entity.eid) diff -r dda74c345b06 -r 1314772c1183 web/views/baseviews.py --- a/web/views/baseviews.py Fri Jan 22 14:40:29 2010 +0100 +++ b/web/views/baseviews.py Fri Jan 22 14:41:08 2010 +0100 @@ -72,13 +72,16 @@ etype = self.cw_rset.description[row][col] value = self.cw_rset.rows[row][col] + if value is None: + self.w(u'') + return if etype == 'String': entity, rtype = self.cw_rset.related_entity(row, col) if entity is not None: # yes ! self.w(entity.printable_value(rtype, value, format=format)) return - if etype in ('Time', 'Interval'): + elif etype in ('Time', 'Interval'): if etype == 'Interval' and isinstance(value, (int, long)): # `date - date`, unlike `datetime - datetime` gives an int # (number of days), not a timedelta diff -r dda74c345b06 -r 1314772c1183 web/views/navigation.py --- a/web/views/navigation.py Fri Jan 22 14:40:29 2010 +0100 +++ b/web/views/navigation.py Fri Jan 22 14:41:08 2010 +0100 @@ -222,7 +222,7 @@ """paginate results if the view is paginable and we're not explictly told to display everything (by setting __force_display in req.form) """ - if not (view.paginable or view._cw.form.get('__force_display')): + if view.paginable ant not view._cw.form.get('__force_display'): do_paginate(view, rset, w or view.w, show_all_option, page_size) # monkey patch base View class to add a .paginate([...])