[Git][debian-gis-team/grass][upstream] New upstream version 7.8.6

Bas Couwenberg (@sebastic) gitlab at salsa.debian.org
Sun Oct 10 16:34:57 BST 2021



Bas Couwenberg pushed to branch upstream at Debian GIS Project / grass


Commits:
574030c0 by Bas Couwenberg at 2021-10-10T16:57:00+02:00
New upstream version 7.8.6
- - - - -


11 changed files:

- display/d.mon/list.c
- doc/howto_release.md
- gui/wxpython/gui_core/mapdisp.py
- gui/wxpython/lmgr/layertree.py
- gui/wxpython/lmgr/pyshell.py
- gui/wxpython/nviz/tools.py
- gui/wxpython/vdigit/preferences.py
- gui/wxpython/vdigit/toolbars.py
- imagery/i.ortho.photo/lib/orthoref.c
- include/VERSION
- lib/python/pygrass/vector/geometry.py


Changes:

=====================================
display/d.mon/list.c
=====================================
@@ -63,7 +63,7 @@ void list_mon(char ***list, int *n)
             continue;
 
         *list = G_realloc(*list, (*n + 1) * sizeof(char *));
-        (*list)[*n] = dp->d_name;
+        (*list)[*n] = G_store(dp->d_name);
         (*n)++;
     }
     closedir(dirp);


=====================================
doc/howto_release.md
=====================================
@@ -1,7 +1,7 @@
 # How to release GRASS GIS binaries and source code
 
 *Note: Some steps in this text are to be done by the development coordinator
-(currently Markus Neteler, PSC Chair) due to needed logins.*
+(currently Markus Neteler and Martin Landa) due to needed logins.*
 
 ## HOWTO create a release
 
@@ -51,7 +51,7 @@ rm -f config.guess config.sub
 wget http://git.savannah.gnu.org/cgit/config.git/plain/config.guess
 wget http://git.savannah.gnu.org/cgit/config.git/plain/config.sub
 git diff config.guess config.sub
-autoconf-2.13
+autoconf2.69
 ```
 
 Now check if configure still works.
@@ -74,16 +74,16 @@ git push origin config_sub_update_r78
 rm -f locale/templates/*.pot
 rm -f locale/po/messages.mo
 rm -f demolocation/PERMANENT/.bash*
-find . -name '*~'     | xargs rm
-find . -name '*.bak'  | xargs rm
-find . -name '*.swp'  | xargs rm
-find . -name '.#*'    | xargs rm
-find . -name '*.orig' | xargs rm
-find . -name '*.rej'  | xargs rm
-find . -name '*.o'    | xargs rm
-find . -name '*.pyc'  | xargs rm
-find . -name 'OBJ.*'  | xargs rm -r
-find . -name '__pycache__' | xargs rm -r
+find . -name '*~'     | xargs -r rm
+find . -name '*.bak'  | xargs -r rm
+find . -name '*.swp'  | xargs -r rm
+find . -name '.#*'    | xargs -r rm
+find . -name '*.orig' | xargs -r rm
+find . -name '*.rej'  | xargs -r rm
+find . -name '*.o'    | xargs -r rm
+find . -name '*.pyc'  | xargs -r rm
+find . -name 'OBJ.*'  | xargs -r rm -r
+find . -name '__pycache__' | xargs -r rm -r
 rm -f lib/python/ctypes/ctypesgencore/parser/lextab.py
 rm -f gui/wxpython/menustrings.py gui/wxpython/build_ext.pyc \
   gui/wxpython/xml/menudata.xml gui/wxpython/xml/module_tree_menudata.xml
@@ -115,11 +115,6 @@ Example:
 2019
 ```
 
-~~Update OSGeo4W setup.hint file~~
-~~no longer needed~~
-~~vim mswindows/osgeo4w/setup_x86.hint.tmpl~~
-~~vim mswindows/osgeo4w/setup_x86_64.hint.tmpl~~
-
 ### Create release tag
 
 (see <https://help.github.com/en/articles/creating-releases>)
@@ -179,7 +174,7 @@ md5sum grass-${VERSION}.tar.gz > grass-${VERSION}.md5sum
 Create Changelog file on release branch:
 
 ```bash
-python tools/gitlog2changelog.py
+python3 tools/gitlog2changelog.py
 mv ChangeLog ChangeLog_$VERSION
 head ChangeLog_$VERSION
 gzip ChangeLog_$VERSION
@@ -219,7 +214,8 @@ Note: grasslxd only reachable via jumphost - https://wiki.osgeo.org/wiki/SAC_Ser
 
 ```bash
 # Store the source tarball (twice) in (use scp -p FILES grass:):
-SERVER1=grasslxd
+USER=neteler
+SERVER1=grass.lxd
 SERVER1DIR=/var/www/code_and_data/grass$MAJOR$MINOR/source/
 SERVER2=upload.osgeo.org
 SERVER2DIR=/osgeo/download/grass/grass$MAJOR$MINOR/source/
@@ -228,26 +224,27 @@ echo $SERVER2:$SERVER2DIR
 
 # upload along with associated files:
 scp -p grass-$VERSION.* AUTHORS COPYING ChangeLog_$VERSION.gz \
-  INSTALL REQUIREMENTS.html SUBMITTING neteler@$SERVER1:$SERVER1DIR
+  INSTALL REQUIREMENTS.html SUBMITTING $USER@$SERVER1:$SERVER1DIR
 
 scp -p grass-$VERSION.* AUTHORS COPYING ChangeLog_$VERSION.gz \
-  INSTALL REQUIREMENTS.html SUBMITTING neteler@$SERVER2:$SERVER2DIR
+  INSTALL REQUIREMENTS.html SUBMITTING $USER@$SERVER2:$SERVER2DIR
 
 # Only at full release!
 # generate link to "latest" source code
-ssh neteler@$SERVER1 "cd $SERVER1DIR ; rm -f grass-$MAJOR.$MINOR-latest.tar.gz"
-ssh neteler@$SERVER1 "cd $SERVER1DIR ; ln -s grass-$VERSION.tar.gz grass-$MAJOR.$MINOR-latest.tar.gz"
-ssh neteler@$SERVER1 "cd $SERVER1DIR ; rm -f grass-$MAJOR.$MINOR-latest.md5sum"
-ssh neteler@$SERVER1 "cd $SERVER1DIR ; ln -s grass-$VERSION.tar.md5sum grass-$MAJOR.$MINOR-latest.md5sum"
+ssh $USER@$SERVER1 "cd $SERVER1DIR ; rm -f grass-$MAJOR.$MINOR-latest.tar.gz"
+ssh $USER@$SERVER1 "cd $SERVER1DIR ; ln -s grass-$VERSION.tar.gz grass-$MAJOR.$MINOR-latest.tar.gz"
+ssh $USER@$SERVER1 "cd $SERVER1DIR ; rm -f grass-$MAJOR.$MINOR-latest.md5sum"
+ssh $USER@$SERVER1 "cd $SERVER1DIR ; ln -s grass-$VERSION.tar.md5sum grass-$MAJOR.$MINOR-latest.md5sum"
 
 # verify
 echo "https://grass.osgeo.org/grass$MAJOR$MINOR/source/"
 
 # update winGRASS related files: Update the winGRASS version
-vim grass-addons/tools/wingrass-packager/grass_packager_release.bat
-vim grass-addons/tools/wingrass-packager/grass_addons.sh
-vim grass-addons/tools/wingrass-packager/grass_copy_wwwroot.sh
-vim grass-addons/tools/wingrass-packager/cronjob.sh       # major/minor release only
+# https://github.com/landam/wingrass-maintenance-scripts
+vim wingrass-maintenance-scripts/grass_packager_release.bat
+vim wingrass-maintenance-scripts/grass_addons.sh
+vim wingrass-maintenance-scripts/grass_copy_wwwroot.sh
+vim wingrass-maintenance-scripts/cronjob.sh       # major/minor release only
 
 # update addons - major/minor release only
 vim grass-addons/tools/addons/grass-addons-publish.sh


=====================================
gui/wxpython/gui_core/mapdisp.py
=====================================
@@ -335,7 +335,8 @@ class MapFrameBase(wx.Frame):
     def StatusbarEnableLongHelp(self, enable=True):
         """Enable/disable toolbars long help"""
         for toolbar in six.itervalues(self.toolbars):
-            toolbar.EnableLongHelp(enable)
+            if toolbar:
+                toolbar.EnableLongHelp(enable)
 
     def IsStandalone(self):
         """Check if map frame is standalone"""


=====================================
gui/wxpython/lmgr/layertree.py
=====================================
@@ -1757,6 +1757,9 @@ class LayerTree(treemixin.DragAndDrop, CT.CustomTreeCtrl):
         If the user is clicking on checkbox, selection change is vetoed.
         """
         if self.hitCheckbox:
+            # Prevent the scrollbar from scrolling up when a layer item
+            # is checked or unchecked
+            self.EnsureVisible(event.GetItem())
             event.Veto()
 
     def OnChangeSel(self, event):


=====================================
gui/wxpython/lmgr/pyshell.py
=====================================
@@ -20,6 +20,8 @@ This program is free software under the GNU General Public License
 
 from __future__ import print_function
 
+import io
+from contextlib import redirect_stdout
 import sys
 
 import wx
@@ -42,15 +44,21 @@ class PyShellWindow(wx.Panel):
 
         wx.Panel.__init__(self, parent=parent, id=id, **kwargs)
 
-        self.intro = _("Welcome to wxGUI Interactive Python Shell %s") % VERSION + "\n\n" + \
-            _("Type %s for more GRASS scripting related information.") % "\"help(grass)\"" + "\n" + \
-            _("Type %s to add raster or vector to the layer tree.") % "\"AddLayer()\"" + "\n\n"
+        self.intro = (
+            _("Welcome to wxGUI Interactive Python Shell %s") % VERSION
+            + "\n\n"
+            + _("Type %s for more GRASS scripting related information.") % '"help(gs)"'
+            + "\n"
+            + _("Type %s to add raster or vector to the layer tree.")
+            % "\"AddLayer('map_name')\""
+            + "\n\n"
+        )
 
         shellargs = dict(
             parent=self,
             id=wx.ID_ANY,
             introText=self.intro,
-            locals={"grass": grass, "AddLayer": self.AddLayer},
+            locals={"gs": grass, "AddLayer": self.AddLayer, "help": self.Help},
         )
         # useStockId (available since wxPython 4.0.2) should be False on macOS
         if sys.platform == "darwin" and CheckWxVersion([4, 0, 2]):
@@ -134,6 +142,17 @@ class PyShellWindow(wx.Panel):
 
         return _('Vector map <%s> added') % fname
 
+    def Help(self, obj):
+        """Override help() function
+
+        :param obj object/str: generate the help of the given object
+
+        return str: help str of the given object
+        """
+        with redirect_stdout(io.StringIO()) as f:
+            help(obj)
+        return f.getvalue()
+
     def OnClear(self, event):
         """Delete all text from the shell
         """


=====================================
gui/wxpython/nviz/tools.py
=====================================
@@ -5719,7 +5719,7 @@ class NvizToolWindow(FN.FlatNotebook):
 
 class PositionWindow(Window):
     """Abstract position control window, see subclasses
-    ViewPostionWindow and LightPositionWindow"""
+    ViewPositionWindow and LightPositionWindow"""
 
     def __init__(self, parent, mapwindow, id=wx.ID_ANY,
                  **kwargs):


=====================================
gui/wxpython/vdigit/preferences.py
=====================================
@@ -25,8 +25,7 @@ from core.debug import Debug
 from gui_core.gselect import ColumnSelect
 from core.units import Units
 from core.settings import UserSettings
-from gui_core.wrap import Button, CheckBox, SpinCtrl, StaticBox, \
-    StaticText
+from gui_core.wrap import Button, CheckBox, FloatSpin, SpinCtrl, StaticBox, StaticText
 
 
 class VDigitSettingsDialog(wx.Dialog):
@@ -206,15 +205,16 @@ class VDigitSettingsDialog(wx.Dialog):
         flexSizer.AddGrowableCol(0)
 
         # snapping
-        text = StaticText(
+        text = StaticText(parent=panel, id=wx.ID_ANY, label=_("Snapping threshold"))
+        self.snappingValue = FloatSpin(
             parent=panel,
             id=wx.ID_ANY,
-            label=_("Snapping threshold"))
-        self.snappingValue = SpinCtrl(
-            parent=panel, id=wx.ID_ANY, size=(75, -1),
-            initial=UserSettings.Get(
-                group='vdigit', key="snapping", subkey='value'),
-            min=-1, max=1e6)
+            size=(75, -1),
+            value=UserSettings.Get(group="vdigit", key="snapping", subkey="value"),
+            min_val=-1,
+            max_val=1e6,
+            digits=7,
+        )
         self.snappingValue.Bind(wx.EVT_SPINCTRL, self.OnChangeSnappingValue)
         self.snappingValue.Bind(wx.EVT_TEXT, self.OnChangeSnappingValue)
         self.snappingUnit = wx.Choice(parent=panel, id=wx.ID_ANY, size=(
@@ -475,13 +475,17 @@ class VDigitSettingsDialog(wx.Dialog):
             parent=panel, id=wx.ID_ANY, choices=[
                 _("shorter than"), _("longer than")])
         self.queryLengthSL.SetSelection(
-            UserSettings.Get(
-                group='vdigit',
-                key="queryLength",
-                subkey='than-selection'))
-        self.queryLengthValue = SpinCtrl(
-            parent=panel, id=wx.ID_ANY, size=(
-                100, -1), initial=1, min=0, max=1e6)
+            UserSettings.Get(group="vdigit", key="queryLength", subkey="than-selection")
+        )
+        self.queryLengthValue = FloatSpin(
+            parent=panel,
+            id=wx.ID_ANY,
+            size=(100, -1),
+            value=1,
+            min_val=0,
+            max_val=1e6,
+            digits=7,
+        )
         self.queryLengthValue.SetValue(
             UserSettings.Get(
                 group='vdigit',
@@ -1003,12 +1007,24 @@ class VDigitSettingsDialog(wx.Dialog):
                          value=int(self.lineWidthValue.GetValue()))
 
         # snapping
-        UserSettings.Set(group='vdigit', key="snapping", subkey='value',
-                         value=int(self.snappingValue.GetValue()))
-        UserSettings.Set(group='vdigit', key="snapping", subkey='unit',
-                         value=self.snappingUnit.GetSelection())
-        UserSettings.Set(group='vdigit', key="snapToVertex", subkey='enabled',
-                         value=self.snapVertex.IsChecked())
+        UserSettings.Set(
+            group="vdigit",
+            key="snapping",
+            subkey="value",
+            value=self.snappingValue.GetValue(),
+        )
+        UserSettings.Set(
+            group="vdigit",
+            key="snapping",
+            subkey="unit",
+            value=self.snappingUnit.GetSelection(),
+        )
+        UserSettings.Set(
+            group="vdigit",
+            key="snapToVertex",
+            subkey="enabled",
+            value=self.snapVertex.IsChecked(),
+        )
 
         # digitize new feature
         UserSettings.Set(group='vdigit', key="addRecord", subkey='enabled',
@@ -1069,10 +1085,9 @@ class VDigitSettingsDialog(wx.Dialog):
         UserSettings.Set(
             group='vdigit',
             key="queryLength",
-            subkey='than-selection',
-            value=self.queryLengthSL.GetSelection())
-        UserSettings.Set(group='vdigit', key="queryLength", subkey='thresh',
-                         value=int(self.queryLengthValue.GetValue()))
+            subkey="thresh",
+            value=self.queryLengthValue.GetValue(),
+        )
         UserSettings.Set(
             group='vdigit',
             key="queryDangle",


=====================================
gui/wxpython/vdigit/toolbars.py
=====================================
@@ -271,6 +271,21 @@ class VDigitToolbar(BaseToolbar):
 
         return self._getToolbarData(data)
 
+    def _noVMapOpenForEditingErrDlg(self):
+        """Show error message dialog if no vector map is open for editing
+
+        :return: True if no vector map is open for editing else None
+        """
+        if not self.digit:
+            GError(
+                _(
+                    "No vector map is open for editing. Please select first"
+                    "a vector map from the combo box."
+                ),
+                self.parent,
+            )
+            return True
+
     def OnTool(self, event):
         """Tool selected -> untoggles previusly selected tool in
         toolbar"""
@@ -599,8 +614,7 @@ class VDigitToolbar(BaseToolbar):
 
     def OnCopy(self, event):
         """Copy selected features from (background) vector map"""
-        if not self.digit:
-            GError(_("No vector map open for editing."), self.parent)
+        if self._noVMapOpenForEditingErrDlg():
             return
 
         # select background map
@@ -763,6 +777,8 @@ class VDigitToolbar(BaseToolbar):
 
     def OnZBulk(self, event):
         """Z bulk-labeling selected lines/boundaries"""
+        if self._noVMapOpenForEditingErrDlg():
+            return
         if not self.digit.IsVector3D():
             GError(parent=self.parent,
                    message=_("Vector map is not 3D. Operation canceled."))


=====================================
imagery/i.ortho.photo/lib/orthoref.c
=====================================
@@ -277,7 +277,7 @@ int I_compute_ortho_equations(struct Ortho_Control_Points *cpz,
 	WT1.x[5][5] = (Q1 / (kappa_var * kappa_var));
     }
     else {
-	G_warning(_("Camera postion not available"));
+	G_warning(_("Camera position not available"));
 #ifdef DEBUG
 	fclose(debug);
 #endif
@@ -547,7 +547,7 @@ int I_compute_ortho_equations(struct Ortho_Control_Points *cpz,
 #endif
 
     }  /* end ITERATION loop */
-    G_verbose_message("%d iterations to refine camera postion", iter);
+    G_verbose_message("%d iterations to refine camera position", iter);
 
     /* This is the solution */
     *XC = epsilon.x[0][0];


=====================================
include/VERSION
=====================================
@@ -1,4 +1,4 @@
 7
 8
-6RC3
+6
 2021


=====================================
lib/python/pygrass/vector/geometry.py
=====================================
@@ -1690,7 +1690,7 @@ class Area(Geo):
                                   int(round_), int(caps), tol,
                                   p_bound, pp_isle, n_isles)
         return (Line(c_points=p_bound.contents),
-                self.centroid,
+                self.centroid(),
                 [Line(c_points=pp_isle[i].contents)
                  for i in range(n_isles.contents.value)])
 



View it on GitLab: https://salsa.debian.org/debian-gis-team/grass/-/commit/574030c0384755f8da931f6d4548619b0600ccca

-- 
View it on GitLab: https://salsa.debian.org/debian-gis-team/grass/-/commit/574030c0384755f8da931f6d4548619b0600ccca
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20211010/66a7164f/attachment-0001.htm>


More information about the Pkg-grass-devel mailing list