- 18 Jul, 2018 3 commits
-
-
Philippe Pepiot authored
--HG-- branch : 3.26
-
Philippe Pepiot authored
--HG-- branch : 3.26
-
Olivier Giorgis authored
--HG-- branch : 3.26
-
- 28 Jun, 2018 11 commits
-
-
Denis Laxalde authored
--HG-- branch : 3.26
-
Denis Laxalde authored
--HG-- branch : 3.26
-
Denis Laxalde authored
Docutils says that "unicode" is an unknown encoding on Python3. Not sure where "unicode" as an encoding comes (it's there since showtime) but "utf-8" seems more appropriate. From now on, rendering of CubicWeb's rst directive (e.g. ..winclude) works on Python 3. Accordingly, we extend wdoc's test to demonstrate this. For this we need to install docutils in tox's web environment. --HG-- branch : 3.26
-
Denis Laxalde authored
This change is needed to make "wdoc" view work on Python 3. Indeed, before this patch, we used to set a "parent" attribute on Element instances, which is not permitted since Python 3.3 as xml.etree.ElementTree uses the C implementation by default. To get rid of this "parent" attribute, we rework the XML nodes processing logic to return and retrieve a node along with its parent in several place of the code. Namely, build_toc_index() now accepts the "parent" value for "node" and inserts it in the "index" dict (thus avoid `node.parent = <value>`). Respectively, every query to the "index" dict is updated to also retrieve the "parent" (thus avoiding `<value> = node.parent`). Later in InlineHelpView class, the "index" dict is bound to "tocindex" attribute so we adjust how it is queried in respective methods. Tests cubicweb/web/test/unittest_views_wdoc.py now pass on Python 3. --HG-- branch : 3.26
-
Denis Laxalde authored
We just make sure it gets rendered without errors (which wasn't the case before the previous patch). It does not work on Python 3; this will be fixed in next changeset. --HG-- branch : 3.26
-
Denis Laxalde authored
Otherwise, UStringIO complains that it receives bytes. --HG-- branch : 3.26
-
Denis Laxalde authored
This argument is deprecated and ignore in docutils since version 0.10. Besides, its default value is None which is the same as we passed. --HG-- branch : 3.26
-
Denis Laxalde authored
Module xml.etree exists since python 2.5. --HG-- branch : 3.26
-
Denis Laxalde authored
Use list(node) as suggested by the deprecation warning. --HG-- branch : 3.26
-
Denis Laxalde authored
--HG-- branch : 3.26
-
Denis Laxalde authored
--HG-- branch : 3.26
-
- 18 Jun, 2018 2 commits
-
-
Denis Laxalde authored
--HG-- branch : 3.26
-
Denis Laxalde authored
--HG-- branch : 3.26
-
- 15 Jun, 2018 1 commit
-
-
Philippe Pepiot authored
publish() must return bytes, when the @ajaxfunc decorated method return None, this raised: TypeError: You cannot set Response.body to a text object (use Response.text) --HG-- branch : 3.26
-
- 13 Jun, 2018 1 commit
-
-
Denis Laxalde authored
The caller of this method (which is method "run_args") does `max(status, self.run_arg(appid))` and run_arg might return None if the underlying <cmdname>_instance method returns None. On python3 max(1, None) breaks with "TypeError: unorderable types: int() > NoneType()". So we enforce run_arg() method to return an integer even if the underlying method returns None. This fixes call of "cubicweb-ctl i18ninstance" with Python3. --HG-- branch : 3.26
-
- 18 Jun, 2018 1 commit
-
-
Denis Laxalde authored
From version 2.0.0, cubicweb-file moved to new-style layout (Python package) but we still expect it to be an old-style cube in CubicWeb's tests (WebconfigTC in web/test/unittest_webconfig.py). --HG-- branch : 3.26
-
- 06 Jun, 2018 1 commit
-
-
Denis Laxalde authored
On Python 3, subprocess' pipes are bytes stream so we must decode them before printing. Without this change, diff of configuration files (e.g. all-in-one.conf as displayed upon instance upgrade) will rendered as a single line on Python 3. --HG-- branch : 3.26
-
- 03 May, 2018 2 commits
-
-
Adrien Di Mascio authored
The ``publish()`` method of controller is supposed to return a bytes intsance. Returning a text_type instance will crash later on in the Pyramid response handler when assigning content to ``response.body`` (at least in Python3):: >>> from pyramid.response import Response >>> r = Response() >>> r.body = '' Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/adim/.virtualenvs/…/response.py", line 562, in _body__set raise TypeError(msg) TypeError: You cannot set Response.body to a text object (use Response.text) --HG-- branch : 3.26
-
Adrien Di Mascio authored
The latter is now deprecated --HG-- branch : 3.26
-
- 12 Oct, 2017 1 commit
-
-
David Douard authored
ie. a situation like: Any X GROUPBY X ORDERBY COUNT(Y) WHERE ... works fine since the aggregation function (COUNT) if the first one, whereas a situation like the proposed test: Any X GROUPBY X ORDERBY ABS(COUNT(Y)) WHERE ... failed due to the fact we only checked the top aggratation function (ABS). Closes #17108671 --HG-- branch : 3.26
-
- 23 Apr, 2018 2 commits
-
-
Denis Laxalde authored
--HG-- branch : 3.26
-
Denis Laxalde authored
--HG-- branch : 3.26
-
- 16 Oct, 2017 1 commit
-
-
David Douard authored
--HG-- branch : 3.26
-
- 13 Dec, 2017 1 commit
-
-
David Douard authored
ensure no fti related process is done when fti is disabled on a db source. --HG-- branch : 3.26
-
- 19 Apr, 2018 4 commits
-
-
David Douard authored
--HG-- branch : 3.26
-
David Douard authored
PropertySheet.process_resource() uses mkstemp which enforce a 0600 mode on the output file, which is not the file permission we want for css files. --HG-- branch : 3.26
-
David Douard authored
--HG-- branch : 3.26
-
David Douard authored
--HG-- branch : 3.26
-
- 22 Mar, 2018 5 commits
-
-
Philippe Pepiot authored
For db-dump (implied by upgrade) and db-restore with postgres with non-trusted authentication, the db password is asked by pg tools (pg_dump, pg_restore, createdb, dropdb). Avoid this behavior by setting the PGPASSWORD environment variable when database driver is postgres and db-password is set in sources file. --HG-- branch : 3.26
-
Denis Laxalde authored
--HG-- branch : 3.26
-
Denis Laxalde authored
--HG-- branch : 3.26
-
Denis Laxalde authored
Having the file flake8 clean makes it easier to catch basic programming errors (e.g. name errors). --HG-- branch : 3.26
-
Denis Laxalde authored
Followup on d84bc85f7f70 which introduced usage of this name in _datadirs method of GenStaticDataDirMixIn but resulted into a NameError at runtime and makes migrations crash. --HG-- branch : 3.26
-
- 15 Feb, 2018 2 commits
-
-
Denis Laxalde authored
--HG-- branch : 3.26
-
Denis Laxalde authored
--HG-- branch : 3.26
-
- 05 Mar, 2018 1 commit
-
-
Denis Laxalde authored
As noted in comment, it might occur that we receive a "sessioneid" from a valid cookie while respective CWSession got dropped (typical case is db being recreated while users got preserved). In such case, we just recreate the CWSession entity as if it did not exist. --HG-- branch : 3.26
-
- 22 Feb, 2018 1 commit
-
-
Denis Laxalde authored
--HG-- branch : 3.26
-