Re: [GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-26 Thread Markus Neteler
On Sat, Aug 26, 2017 at 3:55 PM, Moritz Lennert wrote: > On 26/08/17 14:42, Pietro wrote: >> >> On Fri, Aug 25, 2017 at 5:39 PM, Moritz Lennert >> wrote:

Re: [GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-26 Thread Moritz Lennert
On 26/08/17 14:42, Pietro wrote: On Fri, Aug 25, 2017 at 5:39 PM, Moritz Lennert wrote: https://trac.osgeo.org/grass/browser/grass/tags/release_20170810_grass_7_2_2RC1/lib/python/temporal/core.py#L38 So this probably needs to be taken care of before the

Re: [GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-26 Thread Pietro
On Fri, Aug 25, 2017 at 5:39 PM, Moritz Lennert wrote: >> https://trac.osgeo.org/grass/browser/grass/tags/release_20170810_grass_7_2_2RC1/lib/python/temporal/core.py#L38 > > > So this probably needs to be taken care of before the imminent release. Done in r71438. it

Re: [GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-25 Thread Moritz Lennert
On 25/08/17 17:32, Pietro wrote: On Fri, Aug 25, 2017 at 5:14 PM, Moritz Lennert wrote: On 25/08/17 17:06, Pietro wrote: Unfortunately builtins is used also in other files, and I’m afraid that I should also fix these: Actually most of them are working

Re: [GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-25 Thread Pietro
On Fri, Aug 25, 2017 at 5:14 PM, Moritz Lennert wrote: > On 25/08/17 17:06, Pietro wrote: >> >> Unfortunately builtins is used also in other files, and I’m afraid >> that I should also fix these: Actually most of them are working properly, I was thinking that the

Re: [GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-25 Thread Moritz Lennert
On 25/08/17 17:06, Pietro wrote: Unfortunately builtins is used also in other files, and I’m afraid that I should also fix these: I think that this would be better, yes. Is this in grass72 as well, or only trunk ? Moritz $ rg "builtins" . -B 1 -A 5 script/task.py 24-try: 25:from

Re: [GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-25 Thread Moritz Lennert
On 25/08/17 16:57, Pietro wrote: Hi Moritz, On Thu, Aug 24, 2017 at 4:58 PM, Moritz Lennert wrote: Is the override of the definition of unicode really necessary ? No it is not. it is sufficient replace the try/except with an if. Done in r71435 [0] Great,

Re: [GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-25 Thread Pietro
Unfortunately builtins is used also in other files, and I’m afraid that I should also fix these: $ rg "builtins" . -B 1 -A 5 script/task.py 24-try: 25:from builtins import unicode 26-bytes = str 27-except ImportError: 28-# python3 29-unicode = str 30- temporal/core.py 38-try: 39:

Re: [GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-25 Thread Pietro
Hi Moritz, On Thu, Aug 24, 2017 at 4:58 PM, Moritz Lennert wrote: > Is the override of the definition of unicode really necessary ? No it is not. it is sufficient replace the try/except with an if. Done in r71435 [0]

[GRASS-dev] python script utils encoding/decoding overriding unicode with python-future

2017-08-24 Thread Moritz Lennert
Pietro, In r71394 [1] you changed the unicode handling in decode()/encode() in the python script library. However, this broke things on one of my machines [2] because I didn't have the python-future deb package installed, which is normally not supposed to be a compulsory dependency AFAIK.