Re: [GRASS-dev] [GRASS GIS] #3783: Python 3: ./raster/r.patch/testsuite/test_rpatch_artificial.py is broken

2019-03-06 Thread GRASS GIS
#3783: Python 3: ./raster/r.patch/testsuite/test_rpatch_artificial.py is broken
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  new
  Priority:  normal   |  Milestone:
 Component:  Tests|Version:  svn-trunk
Resolution:   |   Keywords:
   CPU:  Unspecified  |   Platform:  Unspecified
--+-
Description changed by pmav99:

Old description:

> This is the traceback:
> {{{
> ==
> ERROR: test_patching_cell (__main__.TestSmallDataNoOverlap)
> Test patching two neighboring CELL raster maps
> --
> Traceback (most recent call last):
>   File "raster/r.patch/testsuite/test_rpatch_artificial.py", line 162, in
> test_patching_cell
> self.cell_patched_ref, precision=0)
>   File "etc/python/grass/gunittest/case.py", line 767, in
> assertRastersNoDifference
> 'assertRastersNoDifference')
>   File "etc/python/grass/gunittest/case.py", line 681, in
> _compute_difference_raster
> s=second))
>   File "etc/python/grass/gunittest/gmodules.py", line 128, in call_module
> output, errors = process.communicate(input=stdin)
>   File "/usr/lib/python3.7/subprocess.py", line 939, in communicate
> stdout, stderr = self._communicate(input, endtime, timeout)
>   File "/usr/lib/python3.7/subprocess.py", line 1666, in _communicate
> input_view = memoryview(self._input)
> TypeError: memoryview: a bytes-like object is required, not 'str'
> }}}
>
> This is the the suggested fix (git diff):
> {{{
> diff --git a/lib/python/gunittest/case.py b/lib/python/gunittest/case.py
> index cf995e4b2..d94a72b69 100644
> --- a/lib/python/gunittest/case.py
> +++ b/lib/python/gunittest/case.py
> @@ -675,10 +675,12 @@ class TestCase(unittest.TestCase):
>  """
>  diff = self._get_unique_name('compute_difference_raster_' +
> name_part
>   + '_' + first + '_minus_' + second)
> -call_module('r.mapcalc',
> -stdin='"{d}" = "{f}" - "{s}"'.format(d=diff,
> - f=first,
> - s=second))
> +expression = '"{d}" = "{f}" - "{s}"'.format(
> +d=diff,
> +f=first,
> +s=second
> +)
> +call_module('r.mapcalc', stdin=expression.encode("utf-8"))
>  return diff
>
>  # TODO: name of map generation is repeted three times
> }}}
>
> Works on both Python 2 and Python 3

New description:

 This is the traceback:
 {{{
 ==
 ERROR: test_patching_cell (__main__.TestSmallDataNoOverlap)
 Test patching two neighboring CELL raster maps
 --
 Traceback (most recent call last):
   File "raster/r.patch/testsuite/test_rpatch_artificial.py", line 162, in
 test_patching_cell
 self.cell_patched_ref, precision=0)
   File "etc/python/grass/gunittest/case.py", line 767, in
 assertRastersNoDifference
 'assertRastersNoDifference')
   File "etc/python/grass/gunittest/case.py", line 681, in
 _compute_difference_raster
 s=second))
   File "etc/python/grass/gunittest/gmodules.py", line 128, in call_module
 output, errors = process.communicate(input=stdin)
   File "/usr/lib/python3.7/subprocess.py", line 939, in communicate
 stdout, stderr = self._communicate(input, endtime, timeout)
   File "/usr/lib/python3.7/subprocess.py", line 1666, in _communicate
 input_view = memoryview(self._input)
 TypeError: memoryview: a bytes-like object is required, not 'str'
 }}}

 This is the the suggested fix (git diff):
 {{{
 diff --git a/lib/python/gunittest/case.py b/lib/python/gunittest/case.py
 index cf995e4b2..d94a72b69 100644
 --- a/lib/python/gunittest/case.py
 +++ b/lib/python/gunittest/case.py
 @@ -675,10 +675,12 @@ class TestCase(unittest.TestCase):
  """
  diff = self._get_unique_name('compute_difference_raster_' +
 name_part
   + '_' + first + '_minus_' + second)
 -call_module('r.mapcalc',
 -stdin='"{d}" = "{f}" - "{s}"'.format(d=diff,
 - f=first,
 - s=second))
 +expression = '"{diff}" = "{first}" - "{second}"'.format(
 +diff=diff,
 +first=first,
 +second=second
 +)
 +call_module('r.mapcalc', stdin=expression.encode("utf-8"))
  return diff

  # TODO: name of map generation is repeted three times
 }}}

 Works on both Python 2 and Python 3

--

-- 
Ticket URL: 
GRAS

[GRASS-dev] [GRASS GIS] #3783: Python 3: ./raster/r.patch/testsuite/test_rpatch_artificial.py is broken

2019-03-06 Thread GRASS GIS
#3783: Python 3: ./raster/r.patch/testsuite/test_rpatch_artificial.py is broken
-+-
 Reporter:  pmav99   |  Owner:  grass-dev@…
 Type:  defect   | Status:  new
 Priority:  normal   |  Milestone:
Component:  Tests|Version:  svn-trunk
 Keywords:   |CPU:  Unspecified
 Platform:  Unspecified  |
-+-
 This is the traceback:
 {{{
 ==
 ERROR: test_patching_cell (__main__.TestSmallDataNoOverlap)
 Test patching two neighboring CELL raster maps
 --
 Traceback (most recent call last):
   File "raster/r.patch/testsuite/test_rpatch_artificial.py", line 162, in
 test_patching_cell
 self.cell_patched_ref, precision=0)
   File "etc/python/grass/gunittest/case.py", line 767, in
 assertRastersNoDifference
 'assertRastersNoDifference')
   File "etc/python/grass/gunittest/case.py", line 681, in
 _compute_difference_raster
 s=second))
   File "etc/python/grass/gunittest/gmodules.py", line 128, in call_module
 output, errors = process.communicate(input=stdin)
   File "/usr/lib/python3.7/subprocess.py", line 939, in communicate
 stdout, stderr = self._communicate(input, endtime, timeout)
   File "/usr/lib/python3.7/subprocess.py", line 1666, in _communicate
 input_view = memoryview(self._input)
 TypeError: memoryview: a bytes-like object is required, not 'str'
 }}}

 This is the the suggested fix (git diff):
 {{{
 diff --git a/lib/python/gunittest/case.py b/lib/python/gunittest/case.py
 index cf995e4b2..d94a72b69 100644
 --- a/lib/python/gunittest/case.py
 +++ b/lib/python/gunittest/case.py
 @@ -675,10 +675,12 @@ class TestCase(unittest.TestCase):
  """
  diff = self._get_unique_name('compute_difference_raster_' +
 name_part
   + '_' + first + '_minus_' + second)
 -call_module('r.mapcalc',
 -stdin='"{d}" = "{f}" - "{s}"'.format(d=diff,
 - f=first,
 - s=second))
 +expression = '"{d}" = "{f}" - "{s}"'.format(
 +d=diff,
 +f=first,
 +s=second
 +)
 +call_module('r.mapcalc', stdin=expression.encode("utf-8"))
  return diff

  # TODO: name of map generation is repeted three times
 }}}

 Works on both Python 2 and Python 3

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3771: Run tests on Travis

2019-03-06 Thread GRASS GIS
#3771: Run tests on Travis
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  new
  Priority:  normal   |  Milestone:
 Component:  Tests|Version:  svn-trunk
Resolution:   |   Keywords:
   CPU:  Unspecified  |   Platform:  Unspecified
--+-

Comment (by pmav99):

 Running tests on CI doesn't really make sense if you have failing tests:
 http://fatra.cnr.ncsu.edu/grassgistests/summary_report/nc/index.html

 So the next step should be to make the tests pass.

 - Ideally, the failing tests should be fixed.
 - If that is not possible the tests should be marked as expected to fail.
 - If that is not possible then I would suggest removing them for now +
 opening an issue to re-add them when they are fixed (one issue per removed
 test)

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3773: shutil_which() throws an exception on Linux + Python 3

2019-03-06 Thread GRASS GIS
#3773: shutil_which() throws an exception on Linux + Python 3
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  new
  Priority:  normal   |  Milestone:  7.8.0
 Component:  Python   |Version:  svn-trunk
Resolution:   |   Keywords:  python3
   CPU:  Unspecified  |   Platform:  Unspecified
--+-

Comment (by pmav99):

 That's the least invasive patch I can think off:

 {{{
 Index: lib/python/script/core.py
 ===
 --- lib/python/script/core.py   (revision 74173)
 +++ lib/python/script/core.py   (working copy)
 @@ -164,7 +164,7 @@

  return set(cmd), scripts

 -
 +# TODO: Please replace this function with shutil.which() before 8.0 comes
 out
  # replacement for which function from shutil (not available in all
 versions)
  # from http://hg.python.org/cpython/file/6860263c05b3/Lib/shutil.py#l1068
  # added because of Python scripts running Python scripts on MS Windows
 @@ -239,6 +239,8 @@
  return name
  return None

 +if sys.version_info.major > 2:
 +shutil_which = shutil.which

  # Added because of scripts calling scripts on MS Windows.
  # Module name (here cmd) differs from the file name (does not have
 extension).
 }}}

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3779: quadruplicated definition of "do_doctest_gettext_workaround()"

2019-03-06 Thread GRASS GIS
#3779: quadruplicated definition of "do_doctest_gettext_workaround()"
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  new
  Priority:  normal   |  Milestone:
 Component:  Tests|Version:  svn-trunk
Resolution:   |   Keywords:
   CPU:  Unspecified  |   Platform:  Unspecified
--+-

Comment (by neteler):

 If possible please provide a patch, thanks

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3773: shutil_which() throws an exception on Linux + Python 3

2019-03-06 Thread GRASS GIS
#3773: shutil_which() throws an exception on Linux + Python 3
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  new
  Priority:  normal   |  Milestone:  7.8.0
 Component:  Python   |Version:  svn-trunk
Resolution:   |   Keywords:  python3
   CPU:  Unspecified  |   Platform:  Unspecified
--+-

Comment (by neteler):

 Replying to [ticket:3773 pmav99]:
 > A possible resolution could be:
 >
 > {{{
 > import six
 >
 > if six.PY3:
 > shutil_which = shutil.which
 > else:
 > def shutil_which(...):
 > # ...
 > }}}

 Could you please provide a patch? I can also grab it from github if that's
 easier for you.

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] [GRASS GIS] #3782: Python 3: raster/r.in.poly/testsuite/test_rinpoly.py is broken

2019-03-06 Thread GRASS GIS
#3782: Python 3: raster/r.in.poly/testsuite/test_rinpoly.py is broken
-+-
 Reporter:  pmav99   |  Owner:  grass-dev@…
 Type:  defect   | Status:  new
 Priority:  normal   |  Milestone:
Component:  Tests|Version:  svn-trunk
 Keywords:   |CPU:  Unspecified
 Platform:  Unspecified  |
-+-
 This is the error:
 {{{
 =
 ERROR: testLabels (__main__.TestRInPoly)
 Test type of resulting map
 --
 Traceback (most recent call last):
   File "raster/r.in.poly/testsuite/test_rinpoly.py", line 103, in
 testLabels
 self.tmpFile.write(input1)
   File "/usr/lib/python3.7/tempfile.py", line 481, in func_wrapper
 return func(*args, **kwargs)
 TypeError: a bytes-like object is required, not 'str'
 }}}

 The problems is that NamedTemporaryFiles are opened in binary mode by
 default:
 -
 https://docs.python.org/2/library/tempfile.html#tempfile.NamedTemporaryFile
 -
 https://docs.python.org/3/library/tempfile.html#tempfile.NamedTemporaryFile

 This is the git diff for the fix:
 {{{
 diff --git a/raster/r.in.poly/testsuite/test_rinpoly.py
 b/raster/r.in.poly/testsuite/test_rinpoly.py
 index 243dcf9c9..60933bf0c 100644
 --- a/raster/r.in.poly/testsuite/test_rinpoly.py
 +++ b/raster/r.in.poly/testsuite/test_rinpoly.py
 @@ -6,7 +6,7 @@ from grass.script.core import read_command


  input1 = \
 -"""
 +b"""
  A
  634308.630394 223320.356473
  640640.712946 223092.401501
 }}}

 Should work as it is in Python2 too.

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Compilation/Distribution of *.pyc files

2019-03-06 Thread Panagiotis Mavrogiorgos
In continuation of the previous message.

If the compilation of *.py files is indeed important, then copying the *.py
files into dist and issuing

python -m compileall ./dist.x86_64-pc-linux-gnu
>

is going to be orders of magnitudes faster (a single process that compiles
all the files vs creating a new process per *.py file). This is going to be
even faster if only a bunch of *.py files need to be compiled.

Just for comparison on my laptop (using Python 3):

- I need ~5 secs to run make on lib/python
- I need ~8 secs to run make on gui/wxpython
- while I only need ~1 sec to compile all the *.py files using compileall:

$ find ./dist.x86_64-pc-linux-gnu -name '*.pyc' -delete
> $ python -m compileall ./dist.x86_64-pc-linux-gnu
> [...]
>
python -m compileall ./dist.x86_64-pc-linux-gnu  1.10s user 0.11s system
> 99% cpu 1.214 total
>

Re-running compileall is nearly instantaneous:

python -mcompileall ./  0.07s user 0.03s system 99% cpu 0.101 total
>

So, unless someone can clarify why the compilation step is necessary, I
would suggest removing it.
If it is indeed needed, then I would suggest modifying the Makefile rules
to use compileall instead of plain compile

with kind regards,
Panos
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3773: shutil_which() throws an exception on Linux + Python 3

2019-03-06 Thread GRASS GIS
#3773: shutil_which() throws an exception on Linux + Python 3
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  new
  Priority:  normal   |  Milestone:  7.8.0
 Component:  Python   |Version:  svn-trunk
Resolution:   |   Keywords:  python3
   CPU:  Unspecified  |   Platform:  Unspecified
--+-

Comment (by pmav99):

 {{{shutil_which}}} is being used by {{{assertModule}}} which practically
 means that it is not currently possible to run {{{gunnitest}}} based tests
 on Python 3.

 Please prioritize this.

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3781: v.in.geonames - fails in winGRASS7.7 (python3)

2019-03-06 Thread GRASS GIS
#3781: v.in.geonames - fails in winGRASS7.7 (python3)
-+--
  Reporter:  hellik  |  Owner:  grass-dev@…
  Type:  defect  | Status:  new
  Priority:  normal  |  Milestone:  7.8.0
 Component:  Python  |Version:  svn-trunk
Resolution:  |   Keywords:  python3, py3
   CPU:  x86-64  |   Platform:  MSWindows
-+--

Comment (by hellik):

 Replying to [ticket:3781 hellik]:
 > tested with
 >
 > {{{
 > System Info
 > GRASS version: 7.7.svn
 > GRASS SVN revision: r74150M
 > Build date: 2019-03-05
 > Build platform: x86_64-w64-mingw32
 > GDAL: 2.4.0
 > PROJ.4: 5.2.0
 > GEOS: 3.7.0
 > SQLite: 3.26.0
 > Python: 3.7.0
 > wxPython: 4.0.3
 > Platform: Windows-10-10.0.17763-SP0 (OSGeo4W)
 > }}}
 >
 > v.in.geonames fails with
 >
 > {{{
 > v.in.geonames input=D:\data\private\presentation\lernwerkstatt\AT\AT.txt
 output=at_out
 > Traceback (most recent call last):
 >   File
 > "C:\OSGEO4~1\apps\grass\grass77/scripts/v.in.geonames.py",
 > line 150, in 
 > main()
 >   File
 > "C:\OSGEO4~1\apps\grass\grass77/scripts/v.in.geonames.py",
 > line 67, in main
 > num_places = sum(1 for _ in f)
 >   File
 > "C:\OSGEO4~1\apps\grass\grass77/scripts/v.in.geonames.py",
 > line 67, in 
 > num_places = sum(1 for _ in f)
 >   File "C:\OSGEO4~1\apps\Python37\lib\encodings\cp1252.py",
 > line 23, in decode
 > return
 > codecs.charmap_decode(input,self.errors,decoding_table)[0]
 > UnicodeDecodeError: 'charmap' codec can't decode byte 0x9d
 > in position 3815: character maps to 
 > }}}

 same data set works with

 {{{
 GRASS version: 7.6.0
 GRASS SVN revision: r73958
 Build date: 2019-01-17
 Build platform: x86_64-w64-mingw32
 GDAL: 2.4.0
 PROJ.4: 5.2.0
 GEOS: 3.7.0
 SQLite: 3.26.0
 Python: 2.7.14
 wxPython: 2.8.12.1
 Platform: Windows-10-10.0.17763 (OSGeo4W)
 }}}

 {{{
 v.in.geonames input=D:\data\private\presentation\lernwerkstatt\AT\AT.txt
 output=at2
 Converting 51995 place names...
 Scanning input for column types...
 Number of columns: 19
 Number of rows: 51995
 WARNING: Column number 13  defined as string has only integer
 values
 WARNING: Column number 14  defined as string has only integer
 values
 Importing points...
 Populating table...
 Building topology for vector map ...
 Registering primitives...
 (Wed Mar 06 22:25:18 2019) Command finished (9 sec)
 }}}

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] [GRASS GIS] #3781: v.in.geonames - fails in winGRASS7.7 (python3)

2019-03-06 Thread GRASS GIS
#3781: v.in.geonames - fails in winGRASS7.7 (python3)
--+-
 Reporter:  hellik|  Owner:  grass-dev@…
 Type:  defect| Status:  new
 Priority:  normal|  Milestone:  7.8.0
Component:  Python|Version:  svn-trunk
 Keywords:  python3, py3  |CPU:  x86-64
 Platform:  MSWindows |
--+-
 tested with

 {{{
 System Info
 GRASS version: 7.7.svn
 GRASS SVN revision: r74150M
 Build date: 2019-03-05
 Build platform: x86_64-w64-mingw32
 GDAL: 2.4.0
 PROJ.4: 5.2.0
 GEOS: 3.7.0
 SQLite: 3.26.0
 Python: 3.7.0
 wxPython: 4.0.3
 Platform: Windows-10-10.0.17763-SP0 (OSGeo4W)
 }}}

 v.in.geonames fails with

 {{{
 v.in.geonames input=D:\data\private\presentation\lernwerkstatt\AT\AT.txt
 output=at_out
 Traceback (most recent call last):
   File
 "C:\OSGEO4~1\apps\grass\grass77/scripts/v.in.geonames.py",
 line 150, in 
 main()
   File
 "C:\OSGEO4~1\apps\grass\grass77/scripts/v.in.geonames.py",
 line 67, in main
 num_places = sum(1 for _ in f)
   File
 "C:\OSGEO4~1\apps\grass\grass77/scripts/v.in.geonames.py",
 line 67, in 
 num_places = sum(1 for _ in f)
   File "C:\OSGEO4~1\apps\Python37\lib\encodings\cp1252.py",
 line 23, in decode
 return
 codecs.charmap_decode(input,self.errors,decoding_table)[0]
 UnicodeDecodeError: 'charmap' codec can't decode byte 0x9d
 in position 3815: character maps to 
 }}}

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Translations and command description/options

2019-03-06 Thread Panagiotis Mavrogiorgos
On Wed, Mar 6, 2019 at 10:53 PM Markus Neteler  wrote:

> On Wed, Mar 6, 2019 at 9:48 PM Panagiotis Mavrogiorgos 
> wrote:
> > On Wed, Mar 6, 2019 at 10:26 PM Markus Neteler 
> wrote:
> >>
> >> On Wed, Mar 6, 2019 at 8:20 PM Panagiotis Mavrogiorgos <
> pma...@gmail.com> wrote:
> >> >
> >> > hello everyone
> >> >
> >> > After activating the french locale and running GRASS GIS with
> >> >
> >> >> LANG=fr_FR.UTF-8 LANGUAGE=fr_FR.UTF-8 LC_MESSAGES=fr_FR.UTF-8
> bin.x86_64-pc-linux-gnu/grass77
> >>
> >> AFAIK you need to export the variables:
> >>
> >> # the content of my helper script:
> >> [mneteler@oboe ~ ]$ cat ~/bin/fr.sh
> >>  export LANG=fr_FR.UTF-8
> >>  export LANGUAGE=fr_FR.UTF-8
> >>  export LC_MESSAGES=fr_FR.UTF-8
> >>
> >> # sourcing it into the current terminal session
> >> [mneteler@oboe ~ ]$ . ~/bin/fr.sh
> >>
> >> [mneteler@oboe ~ ]$ grass77 ~/grassdata/nc_spm_08_grass7/user1
> >>   __  ___   _____
> >>  / / __ \/   | / ___/ ___/   / /  _/ ___/
> >> / / __/ /_/ / /| | \__ \\_  \   / / __ / / \__ \
> >>/ /_/ / _, _/ ___ |___/ /__/ /  / /_/ // / ___/ /
> >>\/_/ |_/_/  |_///   \/___///
> >>
> >> Bienvenue dans le SIG GRASS 7.7.svn (r74163)
> >> Page d'accueil du SIG GRASS :https://grass.osgeo.org
> >> Cette version fonctionne avec :  Bash Shell (/bin/bash)
> >> L'aide est disponible par la commande :  g.manual -i
> >> Voir les termes de la licence avec : g.version -c
> >> Voir les termes de la licence avec : g.version -x
> >> Démarrer l'interface graphique avec :   g.gui wxpython
> >> Lors prêt pour la fermeture entrer :exit
> >>
> >> GRASS 7.7.svn (nc_spm_08_grass7):~ > r3.cross.rast --help
> >> Créer une section de coupe 2D depuis une carte raster 3D et une carte
> d'altitude 2D
> >>
> >> Utilisation :
> >>  r3.cross.rast [-m] input=string elevation=string output=string
> >>[--overwrite] [--help] [--verbose] [--quiet] [--ui]
> >>
> >> Options :
> >>   -m   Utiliser le masque raster 3D (s'il existe) surnla carte en entrée
>
>
> --> what is your shell?
>
>
I use zsh. I just tried this with bash but I still don't get the
translations, so we can probably rule this out.


> GRASS 7.7.svn (nc_spm_08_grass7):~ > set | grep fr
> LANG=fr_FR
> LANGUAGE=fr_FR
> LC_ADDRESS=fr_FR.UTF-8
> LC_COLLATE=fr_FR.UTF-8
> LC_CTYPE=fr_FR.UTF-8
> LC_IDENTIFICATION=fr_FR.UTF-8
> LC_MEASUREMENT=fr_FR.UTF-8
> LC_MESSAGES=fr_FR.UTF-8
> LC_MONETARY=fr_FR.UTF-8
> LC_NAME=fr_FR.UTF-8
> LC_PAPER=fr_FR.UTF-8
> LC_TELEPHONE=fr_FR.UTF-8
> LC_TIME=fr_FR.UTF-8
>
> .. do you have the same?
>
>
Yes I believe so. Here is mine:

$ set | grep fr

LANG=fr_FR
> LANGUAGE=fr_FR
> LC_ADDRESS=fr_FR.UTF-8
> LC_COLLATE=fr_FR.UTF-8
> LC_CTYPE=fr_FR.UTF-8
> LC_IDENTIFICATION=fr_FR.UTF-8
> LC_MEASUREMENT=fr_FR.UTF-8
> LC_MESSAGES=fr_FR.UTF-8
> LC_MONETARY=fr_FR.UTF-8
> LC_NAME=fr_FR.UTF-8
> LC_PAPER=fr_FR.UTF-8
> LC_TELEPHONE=fr_FR.UTF-8
> LC_TIME=fr_FR.UTF-8
>
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Translations and command description/options

2019-03-06 Thread Markus Neteler
On Wed, Mar 6, 2019 at 9:48 PM Panagiotis Mavrogiorgos  wrote:
> On Wed, Mar 6, 2019 at 10:26 PM Markus Neteler  wrote:
>>
>> On Wed, Mar 6, 2019 at 8:20 PM Panagiotis Mavrogiorgos  
>> wrote:
>> >
>> > hello everyone
>> >
>> > After activating the french locale and running GRASS GIS with
>> >
>> >> LANG=fr_FR.UTF-8 LANGUAGE=fr_FR.UTF-8 LC_MESSAGES=fr_FR.UTF-8 
>> >> bin.x86_64-pc-linux-gnu/grass77
>>
>> AFAIK you need to export the variables:
>>
>> # the content of my helper script:
>> [mneteler@oboe ~ ]$ cat ~/bin/fr.sh
>>  export LANG=fr_FR.UTF-8
>>  export LANGUAGE=fr_FR.UTF-8
>>  export LC_MESSAGES=fr_FR.UTF-8
>>
>> # sourcing it into the current terminal session
>> [mneteler@oboe ~ ]$ . ~/bin/fr.sh
>>
>> [mneteler@oboe ~ ]$ grass77 ~/grassdata/nc_spm_08_grass7/user1
>>   __  ___   _____
>>  / / __ \/   | / ___/ ___/   / /  _/ ___/
>> / / __/ /_/ / /| | \__ \\_  \   / / __ / / \__ \
>>/ /_/ / _, _/ ___ |___/ /__/ /  / /_/ // / ___/ /
>>\/_/ |_/_/  |_///   \/___///
>>
>> Bienvenue dans le SIG GRASS 7.7.svn (r74163)
>> Page d'accueil du SIG GRASS :https://grass.osgeo.org
>> Cette version fonctionne avec :  Bash Shell (/bin/bash)
>> L'aide est disponible par la commande :  g.manual -i
>> Voir les termes de la licence avec : g.version -c
>> Voir les termes de la licence avec : g.version -x
>> Démarrer l'interface graphique avec :   g.gui wxpython
>> Lors prêt pour la fermeture entrer :exit
>>
>> GRASS 7.7.svn (nc_spm_08_grass7):~ > r3.cross.rast --help
>> Créer une section de coupe 2D depuis une carte raster 3D et une carte 
>> d'altitude 2D
>>
>> Utilisation :
>>  r3.cross.rast [-m] input=string elevation=string output=string
>>[--overwrite] [--help] [--verbose] [--quiet] [--ui]
>>
>> Options :
>>   -m   Utiliser le masque raster 3D (s'il existe) surnla carte en entrée

[...]

> That's also what I was expecting to see, because the strings are wrapped with 
> _() and they should be translated, but that's not what I observe... Here is 
> what happens on my PC:
> https://asciinema.org/a/MWCHVRe70tpYJpFVYTMccNKdo
> At 0.11 you can clearly see that command description is not translated.

Indeed!

> So does anyone has any ideas?

Please check this:

GRASS 7.7.svn (nc_spm_08_grass7):~ > echo $SHELL
/bin/bash

--> what is your shell?

GRASS 7.7.svn (nc_spm_08_grass7):~ > set | grep fr
LANG=fr_FR
LANGUAGE=fr_FR
LC_ADDRESS=fr_FR.UTF-8
LC_COLLATE=fr_FR.UTF-8
LC_CTYPE=fr_FR.UTF-8
LC_IDENTIFICATION=fr_FR.UTF-8
LC_MEASUREMENT=fr_FR.UTF-8
LC_MESSAGES=fr_FR.UTF-8
LC_MONETARY=fr_FR.UTF-8
LC_NAME=fr_FR.UTF-8
LC_PAPER=fr_FR.UTF-8
LC_TELEPHONE=fr_FR.UTF-8
LC_TIME=fr_FR.UTF-8

.. do you have the same?

cheers
Markus
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Translations and command description/options

2019-03-06 Thread Panagiotis Mavrogiorgos
On Wed, Mar 6, 2019 at 10:26 PM Markus Neteler  wrote:

> On Wed, Mar 6, 2019 at 8:20 PM Panagiotis Mavrogiorgos 
> wrote:
> >
> > hello everyone
> >
> > After activating the french locale and running GRASS GIS with
> >
> >> LANG=fr_FR.UTF-8 LANGUAGE=fr_FR.UTF-8 LC_MESSAGES=fr_FR.UTF-8
> bin.x86_64-pc-linux-gnu/grass77
>
> AFAIK you need to export the variables:
>
> # the content of my helper script:
> [mneteler@oboe ~ ]$ cat ~/bin/fr.sh
>  export LANG=fr_FR.UTF-8
>  export LANGUAGE=fr_FR.UTF-8
>  export LC_MESSAGES=fr_FR.UTF-8
>
> # sourcing it into the current terminal session
> [mneteler@oboe ~ ]$ . ~/bin/fr.sh
>
> [mneteler@oboe ~ ]$ grass77 ~/grassdata/nc_spm_08_grass7/user1
>   __  ___   _____
>  / / __ \/   | / ___/ ___/   / /  _/ ___/
> / / __/ /_/ / /| | \__ \\_  \   / / __ / / \__ \
>/ /_/ / _, _/ ___ |___/ /__/ /  / /_/ // / ___/ /
>\/_/ |_/_/  |_///   \/___///
>
> Bienvenue dans le SIG GRASS 7.7.svn (r74163)
> Page d'accueil du SIG GRASS :https://grass.osgeo.org
> Cette version fonctionne avec :  Bash Shell (/bin/bash)
> L'aide est disponible par la commande :  g.manual -i
> Voir les termes de la licence avec : g.version -c
> Voir les termes de la licence avec : g.version -x
> Démarrer l'interface graphique avec :   g.gui wxpython
> Lors prêt pour la fermeture entrer :exit
>
> GRASS 7.7.svn (nc_spm_08_grass7):~ > r3.cross.rast --help
> Créer une section de coupe 2D depuis une carte raster 3D et une carte
> d'altitude 2D
>
> Utilisation :
>  r3.cross.rast [-m] input=string elevation=string output=string
>[--overwrite] [--help] [--verbose] [--quiet] [--ui]
>
> Options :
>   -m   Utiliser le masque raster 3D (s'il existe) surnla carte en entrée
>
> Paramètres :
>   input   Carte raste 3D d'entrée pour la section de coupe
>   elevation   Carte 2D d'altitudes pour créer la carte de section de coupe
>  output   Carte raster 2D en sortie de la section de coupe
>
> Looks ok to me...
>
> Markus
>

Thank you Markus

That's also what I was expecting to see, because the strings are wrapped
with _() and they should be translated, but that's not what I observe...
Here is what happens on my PC:
https://asciinema.org/a/MWCHVRe70tpYJpFVYTMccNKdo
At 0.11 you can clearly see that command description is not translated.

So does anyone has any ideas?

Panos
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Test coverage

2019-03-06 Thread Panagiotis Mavrogiorgos
On Wed, Mar 6, 2019 at 10:28 PM Markus Neteler  wrote:

> On Wed, Mar 6, 2019 at 2:34 AM Panagiotis Mavrogiorgos 
> wrote:
> >
> > Q: Is it possible to run coverage with the GRASS testsuite?
>
> Do you mean something like this?
>
> http://fatra.cnr.ncsu.edu/grassgistests/summary_report/nc/index.html
>
> If not, your question isn't yet clear (to me).
>
> Best
> Markus
>

No, I mean using e.g. this tool 
to get a report like this
. I.e. a
report of which lines of code are actually covered by tests and which are
not.
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Test coverage

2019-03-06 Thread Markus Neteler
On Wed, Mar 6, 2019 at 2:34 AM Panagiotis Mavrogiorgos  wrote:
>
> Q: Is it possible to run coverage with the GRASS testsuite?

Do you mean something like this?

http://fatra.cnr.ncsu.edu/grassgistests/summary_report/nc/index.html

If not, your question isn't yet clear (to me).

Best
Markus
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Translations and command description/options

2019-03-06 Thread Markus Neteler
On Wed, Mar 6, 2019 at 8:20 PM Panagiotis Mavrogiorgos 
wrote:
>
> hello everyone
>
> After activating the french locale and running GRASS GIS with
>
>> LANG=fr_FR.UTF-8 LANGUAGE=fr_FR.UTF-8 LC_MESSAGES=fr_FR.UTF-8
bin.x86_64-pc-linux-gnu/grass77

AFAIK you need to export the variables:

# the content of my helper script:
[mneteler@oboe ~ ]$ cat ~/bin/fr.sh
 export LANG=fr_FR.UTF-8
 export LANGUAGE=fr_FR.UTF-8
 export LC_MESSAGES=fr_FR.UTF-8

# sourcing it into the current terminal session
[mneteler@oboe ~ ]$ . ~/bin/fr.sh

[mneteler@oboe ~ ]$ grass77 ~/grassdata/nc_spm_08_grass7/user1
  __  ___   _____
 / / __ \/   | / ___/ ___/   / /  _/ ___/
/ / __/ /_/ / /| | \__ \\_  \   / / __ / / \__ \
   / /_/ / _, _/ ___ |___/ /__/ /  / /_/ // / ___/ /
   \/_/ |_/_/  |_///   \/___///

Bienvenue dans le SIG GRASS 7.7.svn (r74163)
Page d'accueil du SIG GRASS :https://grass.osgeo.org
Cette version fonctionne avec :  Bash Shell (/bin/bash)
L'aide est disponible par la commande :  g.manual -i
Voir les termes de la licence avec : g.version -c
Voir les termes de la licence avec : g.version -x
Démarrer l'interface graphique avec :   g.gui wxpython
Lors prêt pour la fermeture entrer :exit

GRASS 7.7.svn (nc_spm_08_grass7):~ > r3.cross.rast --help
Créer une section de coupe 2D depuis une carte raster 3D et une carte
d'altitude 2D

Utilisation :
 r3.cross.rast [-m] input=string elevation=string output=string
   [--overwrite] [--help] [--verbose] [--quiet] [--ui]

Options :
  -m   Utiliser le masque raster 3D (s'il existe) surnla carte en entrée

Paramètres :
  input   Carte raste 3D d'entrée pour la section de coupe
  elevation   Carte 2D d'altitudes pour créer la carte de section de coupe
 output   Carte raster 2D en sortie de la section de coupe

Looks ok to me...

Markus
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] Translations and command description/options

2019-03-06 Thread Panagiotis Mavrogiorgos
hello everyone

After activating the french locale and running GRASS GIS with

LANG=fr_FR.UTF-8 LANGUAGE=fr_FR.UTF-8 LC_MESSAGES=fr_FR.UTF-8
> bin.x86_64-pc-linux-gnu/grass77


both the GUI and the TUI are translated. E.g.

  __  ___   _____
>  / / __ \/   | / ___/ ___/   / /  _/ ___/
> / / __/ /_/ / /| | \__ \\_  \   / / __ / / \__ \
>/ /_/ / _, _/ ___ |___/ /__/ /  / /_/ // / ___/ /
>\/_/ |_/_/  |_///   \/___///
> Bienvenue dans le SIG GRASS 7.7.svn (exported)
> Page d'accueil du SIG GRASS :https://grass.osgeo.org
> Cette version fonctionne avec :  Z Shell (/usr/bin/zsh)
> L'aide est disponible par la commande :  g.manual -i
> Voir les termes de la licence avec : g.version -c
> Voir les termes de la licence avec : g.version -x
> Si requis, redémarrer l'interface graphique avec :g.gui wxpython
> Lors prêt pour la fermeture entrer : exit




Nevertheless, the command descriptions and options are not. E.g.:

r3.cross.rast --help
> Creates cross section 2D raster map from 3D raster map based on 2D
> elevation map
> Usage:
>  r3.cross.rast [-m] input=string elevation=string output=string
>[--overwrite] [--help] [--verbose] [--quiet] [--ui]
> Flags:
>   -m   Use 3D raster mask (if exists) with input map
> Parameters:
>   input   Input 3D raster map for cross section
>   elevation   2D elevation map used to create the cross section map
>  output   Resulting cross section 2D raster map




The question is: Are command description supposed to be translated too or
not? I mean, is everything working as expected or is there something wrong
in my setup?

with kind regards,
Panos
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] [GRASS GIS] #3780: Python3 + g.gui.animation: Traceback when clicking on the settings button

2019-03-06 Thread GRASS GIS
#3780: Python3 + g.gui.animation: Traceback when clicking on the settings button
-+-
 Reporter:  pmav99   |  Owner:  grass-dev@…
 Type:  defect   | Status:  new
 Priority:  normal   |  Milestone:
Component:  wxGUI|Version:  svn-trunk
 Keywords:   |CPU:  Unspecified
 Platform:  Unspecified  |
-+-
 On Python 3, clicking on the "settings" button, throws an exception:
 {{{
 /home/feanor/Prog/git/grass-p3/repo/dist.x86_64-pc-linux-
 gnu/gui/wxpython/animation/dialogs.py:2007: wxPyDeprecationWarning: Call
 to deprecated item. Use SetToolTip instead.
   "Click and then press key up or down to preview "
 Traceback (most recent call last):
   File "/home/feanor/Prog/git/grass-p3/repo/dist.x86_64-pc-linux-
 gnu/gui/wxpython/animation/frame.py", line 316, in OnPreferences
 dlg = PreferencesDialog(parent=self, giface=self._giface)
   File "/home/feanor/Prog/git/grass-p3/repo/dist.x86_64-pc-linux-
 gnu/gui/wxpython/animation/dialogs.py", line 1855, in __init__
 self._createTemporalPage(self.notebook)
   File "/home/feanor/Prog/git/grass-p3/repo/dist.x86_64-pc-linux-
 gnu/gui/wxpython/animation/dialogs.py", line 2016, in _createTemporalPage
 link = wx.HyperlinkCtrl(
 AttributeError: module 'wx' has no attribute 'HyperlinkCtrl'
 }}}

 PS. Have *not* tested this on python 2

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] [GRASS GIS] #3779: quadruplicated definition of "do_doctest_gettext_workaround()"

2019-03-06 Thread GRASS GIS
#3779: quadruplicated definition of "do_doctest_gettext_workaround()"
-+-
 Reporter:  pmav99   |  Owner:  grass-dev@…
 Type:  defect   | Status:  new
 Priority:  normal   |  Milestone:
Component:  Tests|Version:  svn-trunk
 Keywords:   |CPU:  Unspecified
 Platform:  Unspecified  |
-+-
 {{{do_doctest_gettext_workaround()}}} is being defined 4 times in the
 codebase.

 AFAI can tell, apart from the {{{docstrings}}} there are no differences
 whatsoever.
 {{{
 $  ag 'def do_doctest'
 gui/wxpython/tools/build_modules_xml.py
 33:def do_doctest_gettext_workaround():

 gui/wxpython/core/utils.py
 1155:def do_doctest_gettext_workaround():

 gui/wxpython/core/toolboxes.py
 774:def do_doctest_gettext_workaround():

 lib/python/gunittest/utils.py
 35:def do_doctest_gettext_workaround():
 }}}

 {{{lib/python/gunittest/utils.py}}} seems like the most reasonable place
 to keep this definition. The other definitions should be removed and the
 imports in the gui library should be updated. The docstring at
 {{{gui/wxpython/core/toolboxes.py}}} is the most informative one.

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] [GRASS GIS] #3778: where field in wxgui layer manager d.vect display missing value on workspace import

2019-03-06 Thread GRASS GIS
#3778: where field in wxgui layer manager d.vect display missing value on
workspace import
--+-
 Reporter:  balagates |  Owner:  grass-dev@…
 Type:  defect| Status:  new
 Priority:  normal|  Milestone:
Component:  wxGUI |Version:  svn-releasebranch76
 Keywords:  d.vect where  |CPU:  OSX/Intel
 Platform:  MacOSX|
--+-
 In the WX d.vect Selection tab the "where" field is blank after importing
 a GXW workspace file containing a "where" value (example workspace vector
 parameters below).   The preview of the d.vect command at the bottom of
 the window is also missing the "where" parameter.  The other parameters in
 this workspace file (fill_color and icon) are displayed properly.  The
 strange thing is the Map Display is using the "where" value in the
 workspace file even though it is not displayed in the WX d.vect
 properties.  If I manually type in the same "where" value the WX d.vect
 works as expected.  So this appears to be only a WX d.vect Selection
 display problem after import from a GXW workspace file.

 {{{
 
 
 
 mrds_az@brett
 
 
 COMMOD1='Gold'
 
 
 orange
 
 
 basic/box
 
 
 
 }}}



 I believe this worked fine in 7.4.1.  I first noticed the problem in the
 7.6.0 downloaded from the Grass site on my macOS 10.12.6.

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #2048: i.pansharpen limited to 8-bit imagery

2019-03-06 Thread GRASS GIS
#2048: i.pansharpen limited to 8-bit imagery
-+-
  Reporter:  Nikos   |  Owner:  grass-dev@…
  Alexandris |
  Type:  defect  | Status:  new
  Priority:  normal  |  Milestone:  7.6.1
 Component:  Imagery |Version:  svn-trunk
Resolution:  |   Keywords:  i.pansharpen, sharpening, fusion,
 |  brovey, ihs, pca, 8-bit
   CPU:  All |   Platform:  Unspecified
-+-

Comment (by cmbarton):

 Niko, I'm not sure that much of the code--or assumptions underlying the
 pan sharpening--would work or make sense for bit depth <8.

 I can check of course. The main reason to have user input for bit depth is
 to be able to calculate the potential raster value range to rescale to 8
 bit for processing. This still assumes an integer raster rather than a
 floating point one.

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Editing issue descriptions

2019-03-06 Thread Markus Neteler
Nikos Alexandris  schrieb am Mi., 6. März 2019,
12:44:

> * Markus Neteler  [2019-03-06 11:56:26 +0100]:
>
> >On Wed, Mar 6, 2019 at 10:47 AM Nikos Alexandris
> > wrote:
> >> Btw, Ihave never had the "edit" option for my tickets.  And I would like
> >> to have this right too.
> >
> >Sure:
> >
> >Nikos Alexandris has been granted the permission TICKET_EDIT_DESCRIPTION.
> >
> >Unfortunately to be done user by user...
>
> :-/
>

Another reason for migrating :)

Markus


N
>
>
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] [GRASS GIS] #3777: vector digitizer crashes with python 3

2019-03-06 Thread GRASS GIS
#3777: vector digitizer crashes with python 3
---+-
 Reporter:  veroandreo |  Owner:  grass-dev@…
 Type:  defect | Status:  new
 Priority:  normal |  Milestone:  7.8.0
Component:  wxGUI  |Version:  svn-trunk
 Keywords:  vector digitizer, python3  |CPU:  Unspecified
 Platform:  Linux  |
---+-
 When changing to vector digitizer mode in Map Display and attempting to
 create a new vector map to start digitizing, it crashes and I get the
 following in the GUI Console tab:

 {{{
 Traceback (most recent call last):
   File
 "/home/veroandreo/software/grass7_trunk/dist.x86_64-pc-
 linux-gnu/gui/wxpython/vdigit/toolbars.py", line 818, in
 OnSelectMap

 disableAdd=True)
   File
 "/home/veroandreo/software/grass7_trunk/dist.x86_64-pc-
 linux-gnu/gui/wxpython/gui_core/dialogs.py", line 520, in
 CreateNewVector

 stdin=sql)
   File
 "/home/veroandreo/software/grass7_trunk/dist.x86_64-pc-
 linux-gnu/gui/wxpython/core/gcmd.py", line 719, in
 RunCommand

 ps.stdin.write(stdin)
 TypeError
 :
 a bytes-like object is required, not 'str'
 }}}

 I use trunk r74162 in a virtualenv with python3.

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Editing issue descriptions

2019-03-06 Thread Nikos Alexandris

* Markus Neteler  [2019-03-06 11:56:26 +0100]:


On Wed, Mar 6, 2019 at 10:47 AM Nikos Alexandris
 wrote:

Btw, Ihave never had the "edit" option for my tickets.  And I would like
to have this right too.


Sure:

Nikos Alexandris has been granted the permission TICKET_EDIT_DESCRIPTION.

Unfortunately to be done user by user...


:-/

N

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #2048: i.pansharpen limited to 8-bit imagery

2019-03-06 Thread GRASS GIS
#2048: i.pansharpen limited to 8-bit imagery
-+-
  Reporter:  Nikos   |  Owner:  grass-dev@…
  Alexandris |
  Type:  defect  | Status:  new
  Priority:  normal  |  Milestone:  7.6.1
 Component:  Imagery |Version:  svn-trunk
Resolution:  |   Keywords:  i.pansharpen, sharpening, fusion,
 |  brovey, ihs, pca, 8-bit
   CPU:  All |   Platform:  Unspecified
-+-

Comment (by Nikos Alexandris):

 Replying to [comment:29 cmbarton]:
 > To follow up with the proposal in comment 28 above, the easiest approach
 would be to add the option for the user to select bit depth (following one
 of the suggestions in the comments). I would add options for 8, 11, and 16
 bit. Any reason to include 32 bit or other?

 Dear Michael, it's great you work on this!  I would leave all the range
 [2, 16] or [2, 32] open to the user.  One never knows what needs there
 might be.

 However,

 - for bitness < 2, there I have a comment here
 
https://github.com/NikosAlexandris/test_color_space_conversions/blob/master/test_color_space_roundtrips.py#L31
 about an `r.rescale` flaw which means, my test failed for `bitness = 2`.

 - for bitness >= 15 the test will fail for precision precision to 0.001

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #2048: i.pansharpen limited to 8-bit imagery

2019-03-06 Thread GRASS GIS
#2048: i.pansharpen limited to 8-bit imagery
-+-
  Reporter:  Nikos   |  Owner:  grass-dev@…
  Alexandris |
  Type:  defect  | Status:  new
  Priority:  normal  |  Milestone:  7.6.1
 Component:  Imagery |Version:  svn-trunk
Resolution:  |   Keywords:  i.pansharpen, sharpening, fusion,
 |  brovey, ihs, pca, 8-bit
   CPU:  All |   Platform:  Unspecified
-+-

Comment (by cmbarton):

 To follow up with the proposal in comment 28 above, the easiest approach
 would be to add the option for the user to select bit depth (following one
 of the suggestions in the comments). I would add options for 8, 11, and 16
 bit. Any reason to include 32 bit or other?

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3487: vector digitizer unstable

2019-03-06 Thread GRASS GIS
#3487: vector digitizer unstable
+---
  Reporter:  cmbarton   |  Owner:  grass-dev@…
  Type:  defect | Status:  new
  Priority:  critical   |  Milestone:  7.6.1
 Component:  wxGUI  |Version:  7.2.2
Resolution: |   Keywords:  digitizer, ctypes
   CPU:  OSX/Intel  |   Platform:  MacOSX
+---

Comment (by cmbarton):

 Thanks for the additional info

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3774: lib/gis/testsuite/test_parser_json.py are failing

2019-03-06 Thread GRASS GIS
#3774: lib/gis/testsuite/test_parser_json.py are failing
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  reopened
  Priority:  normal   |  Milestone:
 Component:  Tests|Version:  svn-trunk
Resolution:   |   Keywords:
   CPU:  Unspecified  |   Platform:  Unspecified
--+-
Changes (by neteler):

 * status:  closed => reopened
 * resolution:  fixed =>


-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Editing issue descriptions

2019-03-06 Thread Markus Neteler
On Wed, Mar 6, 2019 at 10:47 AM Nikos Alexandris
 wrote:
> Btw, Ihave never had the "edit" option for my tickets.  And I would like
> to have this right too.

Sure:

Nikos Alexandris has been granted the permission TICKET_EDIT_DESCRIPTION.

Unfortunately to be done user by user...

Best
Markus
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] On bitness about RGB to HIS to RGB

2019-03-06 Thread Nikos Alexandris

Dear all,

this is a kind reminder for the following modules

https://trac.osgeo.org/grass/browser/sandbox/alexandris/i.rgb.his/
(or https://github.com/NikosAlexandris/i.rgb.his)

and

https://trac.osgeo.org/grass/browser/sandbox/alexandris/i.his.rgb/
(or https://github.com/NikosAlexandris/i.his.rgb)

and the test

https://github.com/NikosAlexandris/test_color_space_conversions/blob/master/test_color_space_roundtrips.py
(or
https://gitlab.com/NikosAlexandris/test_color_space_conversions/blob/master/test_color_space_roundtrips.py)

Everything is detailed at https://trac.osgeo.org/grass/ticket/774#comment:13;
https://trac.osgeo.org/grass/ticket/774#comment:21.

Since Michael Barton wants to re-work on ticket
https://trac.osgeo.org/grass/ticket/2048, it's good to have ticket #774 fixed
first.

In my very humble view, regarding ticket #2048, it is not acceptable to
sacrifice bits, i.e. input 16-bit and output 8-bit.  At the very least,
give the user the option to decide what to do.

Kind regards, Nikos
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Editing issue descriptions

2019-03-06 Thread Nikos Alexandris

* Markus Neteler  [2019-03-05 23:17:14 +0100]:


On Tue, Mar 5, 2019 at 11:03 PM Panagiotis Mavrogiorgos
 wrote:

I am afraid that I don't see it: 
https://screenshots.firefox.com/A73gnNzs8SKEKeKE/trac.osgeo.org

Google suggests that TICKET_EDIT_DESCRIPTION needs to be granted in order to be 
have the permission to edit.


I see

--> pmav99 has been granted the permission TICKET_EDIT_DESCRIPTION.

Please try again. Probably you need to logout/login for that.


Btw, Ihave never had the "edit" option for my tickets.  And I would like
to have this right too.

Thank you, Nikos.


___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Introduction and Idea ( GSOC 2019 )

2019-03-06 Thread Stefan Blumentrath
Hi guys,

First of all, I have to mention, that I have almost no experience with kind of 
models. From tensorflow I have been looking a bit at tensorflow probability[1].
Could imagine that also v.class.ml[2] and r.learn.ml[3] could give some 
inspiration how such libraries could be plugged into GRASS in principle. Other 
interesting modelling libraries would be PyMC3[4] or Stan[5].
Just for mentioning it.

I can imagine that IO is particularly important for parallelism in these 
libraries...
Maybe it would be possible develop a general framework for this?

Cheers
Stefan

1: https://www.tensorflow.org/probability
2: https://grass.osgeo.org/grass74/manuals/addons/v.class.ml.html
3: https://grass.osgeo.org/grass74/manuals/addons/r.learn.ml.html
4: https://docs.pymc.io/
5: https://mc-stan.org/

-Original Message-
From: grass-dev  On Behalf Of Maris Nartiss
Sent: tirsdag 5. mars 2019 18:00
To: Luca Delucchi 
Cc: Soumya kanta Das ; GRASS-dev 

Subject: Re: [GRASS-dev] Introduction and Idea ( GSOC 2019 )

Hello,
svētd., 2019. g. 3. marts, plkst. 08:50 — lietotājs Luca Delucchi
() rakstīja:
>
> On Sat, 2 Mar 2019 at 18:48, Soumya kanta Das 
>  wrote:
> >
> > Hello,
>
> Hi,
>
> > Myself Soumya Kanta Das, studying Geo-informatics. Currently i work on 
> > automating geospatial workflow and Machine learning applications. I have 
> > previously worked on automated identification of buildings in Satellite 
> > imagery using Deep learning. I have language proficiency in python.
> >
> > I would like to develop a Deep learning module for grass using tensorflow 
> > library and python 3. Which would be very helpful for end-users.
> >
>
> something already exists in GRASS GIS addons using tensorflow [0], you 
> can have look there..

I have a working prototype of GRASS – Keras bridge (still needs a lot of work 
to fix all edge cases + support of second image_data_format).
My first approach was to use pure Python code, but it turned out to be reay 
slooow. Large parts have to be written in C (linked via ctypes). Currently 
there still is a speed penality due to GRASS raster code not supporting 
mutlithreaded applications. It all can be worked around.

Developing any high speed interface between ML libraries and GRASS needs some 
(good) understanding of working with multidimensional arrays in C and GRASS 
rasters in C.

> > Thank you.
> >
>
> [0] https://grass.osgeo.org/grass74/manuals/addons/i.ann.maskrcnn.html
>
> --
> ciao
> Luca

Just FYI,
Māris.
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3774: lib/gis/testsuite/test_parser_json.py are failing

2019-03-06 Thread GRASS GIS
#3774: lib/gis/testsuite/test_parser_json.py are failing
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  closed
  Priority:  normal   |  Milestone:
 Component:  Tests|Version:  svn-trunk
Resolution:  fixed|   Keywords:
   CPU:  Unspecified  |   Platform:  Unspecified
--+-

Comment (by pmav99):

 @neteler yes, I am sorry, I should have elaborated a bit more.

 That was the output of the tests that show the differences between
 expected and actual output. The lines that throw the errors are 46 and 74.

 I don't feel comfortable suggesting a fix here, because I am not familiar
 enough with fully qualified map names and their nuances. In other words I
 can't really judge if the error is in the test itself or in the tested
 code. But the test is failing and needs to be fixed.

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] Passed: GRASS-GIS/grass-ci#3306 (master - 57e09b1)

2019-03-06 Thread Travis CI
Build Update for GRASS-GIS/grass-ci
-

Build: #3306
Status: Passed

Duration: 9 mins and 23 secs
Commit: 57e09b1 (master)
Author: Markus Neteler
Message: t.rast.series testsuite: missing bracket added (fixes #3741) 
(contributed by pmav99)

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@74161 
15284696-431f-4ddb-bdfa-cd5b030d7da7

View the changeset: 
https://github.com/GRASS-GIS/grass-ci/compare/ec426fb79952...57e09b16ec22

View the full build log and details: 
https://travis-ci.org/GRASS-GIS/grass-ci/builds/502451867?utm_medium=notification&utm_source=email

--

You can unsubscribe from build emails from the GRASS-GIS/grass-ci repository 
going to 
https://travis-ci.org/account/preferences/unsubscribe?repository=5458449&utm_medium=notification&utm_source=email.
Or unsubscribe from *all* email updating your settings at 
https://travis-ci.org/account/preferences/unsubscribe?utm_medium=notification&utm_source=email.
Or configure specific recipients for build notifications in your .travis.yml 
file. See https://docs.travis-ci.com/user/notifications.

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Errored: GRASS-GIS/grass-ci#3305 (master - ec426fb)

2019-03-06 Thread Bas Couwenberg

On 2019-03-06 09:25, Markus Neteler wrote:

$ ./.travis/$TRAVIS_OS_NAME.before_install.sh
Error: retrieving gpg key timed out.
gpg: keyring `/tmp/tmpe6iyl625/secring.gpg' created
gpg: keyring `/tmp/tmpe6iyl625/pubring.gpg' created
gpg: requesting key 314DF160 from hkp server keyserver.ubuntu.com
gpg: /tmp/tmpe6iyl625/trustdb.gpg: trustdb created
gpg: key 314DF160: public key "Launchpad ubuntugis-stable" imported
gpg: Total number processed: 1
gpg: imported: 1 (RSA: 1)
OK
The command "./.travis/$TRAVIS_OS_NAME.before_install.sh" failed and
exited with 1 during .

... not sure what this means?


Looks like adding the UbuntuGIS PPA failed, i.e. this command:

 sudo add-apt-repository ppa:ubuntugis/ubuntugis-unstable -y

Most likely a transient issue, try again to see if it still fails.

Kind Regards,

Bas
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3774: lib/gis/testsuite/test_parser_json.py are failing

2019-03-06 Thread GRASS GIS
#3774: lib/gis/testsuite/test_parser_json.py are failing
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  closed
  Priority:  normal   |  Milestone:
 Component:  Tests|Version:  svn-trunk
Resolution:  fixed|   Keywords:
   CPU:  Unspecified  |   Platform:  Unspecified
--+-

Comment (by neteler):

 Thanks for catching this.

 Replying to [ticket:3774 pmav99]:
 >
 > {{{
 > - [{'param': 'input', 'value': 'hospitals'},
 > + [{'param': 'input', 'value': 'hospitals@PERMANENT'},
 > }}}

 ... this code I didn't find. Where is that located?

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3774: lib/gis/testsuite/test_parser_json.py are failing

2019-03-06 Thread GRASS GIS
#3774: lib/gis/testsuite/test_parser_json.py are failing
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  closed
  Priority:  normal   |  Milestone:
 Component:  Tests|Version:  svn-trunk
Resolution:  fixed|   Keywords:
   CPU:  Unspecified  |   Platform:  Unspecified
--+-
Changes (by neteler):

 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"74162" 74162]:
 {{{
 #!CommitTicketReference repository="" revision="74162"
 test_parser_json.py testsuite: use json instead of simplejson (fixes
 #3774) (contributed by pmav99)
 }}}

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3741: t.rast.series: allow multiple methods/output

2019-03-06 Thread Stefan Blumentrath
Thanks for both catching and fixing it.
Should not have happened in the first place. I need to improve my routines 
here, sorry...

Cheers
Stefan

-Original Message-
From: GRASS GIS  
Sent: onsdag 6. mars 2019 09:30
Cc: grass-dev@lists.osgeo.org
Subject: Re: [GRASS GIS] #3741: t.rast.series: allow multiple methods/output

#3741: t.rast.series: allow multiple methods/output
--+---
  Reporter:  sbl  |  Owner:  grass-dev@…
  Type:  enhancement  | Status:  closed
  Priority:  normal   |  Milestone:  7.8.0
 Component:  Temporal |Version:  svn-trunk
Resolution:  fixed|   Keywords:  t.rast.series
   CPU:  All  |   Platform:  All
--+---

Comment (by neteler):

 In [changeset:"74161" 74161]:
 {{{
 #!CommitTicketReference repository="" revision="74161"
 t.rast.series testsuite: missing bracket added (fixes #3741) (contributed  by 
pmav99)  }}}

--
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3741: t.rast.series: allow multiple methods/output

2019-03-06 Thread GRASS GIS
#3741: t.rast.series: allow multiple methods/output
--+---
  Reporter:  sbl  |  Owner:  grass-dev@…
  Type:  enhancement  | Status:  closed
  Priority:  normal   |  Milestone:  7.8.0
 Component:  Temporal |Version:  svn-trunk
Resolution:  fixed|   Keywords:  t.rast.series
   CPU:  All  |   Platform:  All
--+---

Comment (by neteler):

 In [changeset:"74161" 74161]:
 {{{
 #!CommitTicketReference repository="" revision="74161"
 t.rast.series testsuite: missing bracket added (fixes #3741) (contributed
 by pmav99)
 }}}

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Errored: GRASS-GIS/grass-ci#3305 (master - ec426fb)

2019-03-06 Thread Markus Neteler
Hi,

On Wed, Mar 6, 2019 at 9:20 AM Travis CI  wrote:
>
> GRASS-GIS / grass-ci
>
> master
>
> Build #3305 has errored
> 9 mins and 57 secs
> Markus Neteler
> ec426fb CHANGESET →
>
> testsuite: fix typo (fixes #3776)
>
> git-svn-id: https://svn.osgeo.org/grass/grass/trunk@74159 
> 15284696-431f-4ddb-bdfa-cd5b030d7da7

Here the log:

Setting environment variables from .travis.yml
$ export CFLAGS="-Werror=implicit-function-declaration"
$ export TRAVIS_COMPILER=gcc
$ export CC=gcc
$ export CC_FOR_BUILD=gcc
$ gcc --version
gcc (Ubuntu 5.4.0-6ubuntu1~16.04.11) 5.4.0 20160609
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
96.98s

$ ./.travis/$TRAVIS_OS_NAME.before_install.sh
Error: retrieving gpg key timed out.
gpg: keyring `/tmp/tmpe6iyl625/secring.gpg' created
gpg: keyring `/tmp/tmpe6iyl625/pubring.gpg' created
gpg: requesting key 314DF160 from hkp server keyserver.ubuntu.com
gpg: /tmp/tmpe6iyl625/trustdb.gpg: trustdb created
gpg: key 314DF160: public key "Launchpad ubuntugis-stable" imported
gpg: Total number processed: 1
gpg: imported: 1 (RSA: 1)
OK
The command "./.travis/$TRAVIS_OS_NAME.before_install.sh" failed and
exited with 1 during .

... not sure what this means?

Markus
___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] Errored: GRASS-GIS/grass-ci#3305 (master - ec426fb)

2019-03-06 Thread Travis CI
Build Update for GRASS-GIS/grass-ci
-

Build: #3305
Status: Errored

Duration: 9 mins and 57 secs
Commit: ec426fb (master)
Author: Markus Neteler
Message: testsuite: fix typo (fixes #3776)

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@74159 
15284696-431f-4ddb-bdfa-cd5b030d7da7

View the changeset: 
https://github.com/GRASS-GIS/grass-ci/compare/72f86150a276...ec426fb79952

View the full build log and details: 
https://travis-ci.org/GRASS-GIS/grass-ci/builds/502446007?utm_medium=notification&utm_source=email

--

You can unsubscribe from build emails from the GRASS-GIS/grass-ci repository 
going to 
https://travis-ci.org/account/preferences/unsubscribe?repository=5458449&utm_medium=notification&utm_source=email.
Or unsubscribe from *all* email updating your settings at 
https://travis-ci.org/account/preferences/unsubscribe?utm_medium=notification&utm_source=email.
Or configure specific recipients for build notifications in your .travis.yml 
file. See https://docs.travis-ci.com/user/notifications.

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] [GRASS GIS] #3776: SyntaxError at lib/python/gunittest/testsuite/data/samplecode/testsuite/test_python_unittest.py

2019-03-06 Thread GRASS GIS
#3776: SyntaxError at
lib/python/gunittest/testsuite/data/samplecode/testsuite/test_python_unittest.py
--+-
  Reporter:  pmav99   |  Owner:  grass-dev@…
  Type:  defect   | Status:  closed
  Priority:  normal   |  Milestone:
 Component:  Tests|Version:  svn-trunk
Resolution:  fixed|   Keywords:
   CPU:  Unspecified  |   Platform:  Unspecified
--+-
Changes (by neteler):

 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"74159" 74159]:
 {{{
 #!CommitTicketReference repository="" revision="74159"
 testsuite: fix typo (fixes #3776)
 }}}

-- 
Ticket URL: 
GRASS GIS 

___
grass-dev mailing list
grass-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-dev