[qgis] 01/07: New upstream version 2.14.19+dfsg
Bas Couwenberg
sebastic at debian.org
Fri Sep 15 23:28:09 UTC 2017
This is an automated email from the git hooks/post-receive script.
sebastic pushed a commit to branch master
in repository qgis.
commit bf0aef6261314997e7174290f9053077e9f12f09
Author: Bas Couwenberg <sebastic at xs4all.nl>
Date: Fri Sep 15 22:50:43 2017 +0200
New upstream version 2.14.19+dfsg
---
.travis.yml | 1 +
CMakeLists.txt | 2 +-
ChangeLog | 20 ++++++++++++++++++++
debian/changelog | 10 ++++++++--
python/core/__init__.py | 3 ++-
python/core/qgscoordinatetransform.sip | 1 -
src/server/qgswmsserver.cpp | 10 +++++++---
tests/src/python/test_qgsexpression.py | 24 ++++++++++++++++++++++++
8 files changed, 63 insertions(+), 8 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index 1d6e070..ea9f9a5 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -10,6 +10,7 @@ matrix:
- BUILD=qt4
- QT_VERSION=4
# - LLVM_VERSION=3.8
+ dist: precise
sudo: false
cache:
apt: true
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 2733a16..9d34962 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,6 +1,6 @@
SET(CPACK_PACKAGE_VERSION_MAJOR "2")
SET(CPACK_PACKAGE_VERSION_MINOR "14")
-SET(CPACK_PACKAGE_VERSION_PATCH "18")
+SET(CPACK_PACKAGE_VERSION_PATCH "19")
SET(COMPLETE_VERSION ${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH})
SET(RELEASE_NAME "Essen")
IF (POLICY CMP0048) # in CMake 3.0.0+
diff --git a/ChangeLog b/ChangeLog
index 6b6bb71..475f902 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,23 @@
+rldhont <rldhont at gmail.com> 2017-09-12
+
+ [BUFIX][Server] GetFeatureInfo on Raster Layer, fix valid identify
+
+ Needs to be manually apply to QGIS 3
+
+ Funded by Ifremer
+
+Etienne Trimaille <gustrimaille at yahoo.fr> 2017-09-05
+
+ [backport on 2.14] enable custom help in python expressions
+
+Juergen E. Fischer <jef at norbit.de> 2017-08-20
+
+ remove sip workaround (fixes #17038, refs #16071)
+
+Juergen E. Fischer <jef at norbit.de> 2017-08-18
+
+ Release of 2.14.18
+
Larry Shaffer <lshaffer at boundlessgeo.com> 2017-08-14
Add QSCINTILLA_INCLUDE_DIR to custom widgets CMake setup
diff --git a/debian/changelog b/debian/changelog
index 675e710..0a402e8 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,8 +1,14 @@
-qgis (2.14.18) UNRELEASED; urgency=medium
+qgis (2.14.19) UNRELEASED; urgency=medium
+
+ * Release of 2.14.19
+
+ -- Jürgen E. Fischer <jef at norbit.de> Fri, 15 Sep 2017 15:08:40 +0200
+
+qgis (2.14.18) unstable; urgency=medium
* Release of 2.14.18
- -- Jürgen E. Fischer <jef at norbit.de> Fri, 18 Aug 2017 14:31:42 +0200
+ -- Jürgen E. Fischer <jef at norbit.de> Fri, 15 Sep 2017 15:08:40 +0200
qgis (2.14.17) unstable; urgency=medium
diff --git a/python/core/__init__.py b/python/core/__init__.py
index a150bb4..67b5233 100644
--- a/python/core/__init__.py
+++ b/python/core/__init__.py
@@ -83,7 +83,7 @@ def register_function(function, arg_count, group, usesgeometry=False, referenced
helptemplate = string.Template("""<h3>$name function</h3><br>$doc""")
name = kwargs.get('name', function.__name__)
- helptext = function.__doc__ or ''
+ helptext = kwargs.get('help_text') or function.__doc__ or ''
helptext = helptext.strip()
expandargs = False
@@ -138,6 +138,7 @@ def qgsfunction(args='auto', group='custom', **kwargs):
return register_function(func, args, group, **kwargs)
return wrapper
+
try:
# Add a __nonzero__ method onto QPyNullVariant so we can check for null values easier.
# >>> value = QPyNullVariant("int")
diff --git a/python/core/qgscoordinatetransform.sip b/python/core/qgscoordinatetransform.sip
index f9b7854..464952d 100644
--- a/python/core/qgscoordinatetransform.sip
+++ b/python/core/qgscoordinatetransform.sip
@@ -15,7 +15,6 @@
class QgsCoordinateTransform : QObject
{
%TypeHeaderCode
-extern PyObject *sipExportedExceptions__core[2]; // workaround: sipExportedExceptions__core is only defined in the first sip part
#include <qgscoordinatetransform.h>
%End
diff --git a/src/server/qgswmsserver.cpp b/src/server/qgswmsserver.cpp
index 1520e25..f0ba8df 100644
--- a/src/server/qgswmsserver.cpp
+++ b/src/server/qgswmsserver.cpp
@@ -2535,19 +2535,23 @@ int QgsWMSServer::featureInfoFromRasterLayer( QgsRasterLayer* layer,
{
return 1;
}
- QMap<int, QVariant> attributes;
+ QgsRasterIdentifyResult identifyResult;
// use context extent, width height (comes with request) to use WCS cache
// We can only use context if raster is not reprojected, otherwise it is difficult
// to guess correct source resolution
if ( mMapRenderer->hasCrsTransformEnabled() && layer->dataProvider()->crs() != mMapRenderer->destinationCrs() )
{
- attributes = layer->dataProvider()->identify( *infoPoint, QgsRaster::IdentifyFormatValue ).results();
+ identifyResult = layer->dataProvider()->identify( *infoPoint, QgsRaster::IdentifyFormatValue );
}
else
{
- attributes = layer->dataProvider()->identify( *infoPoint, QgsRaster::IdentifyFormatValue, mMapRenderer->extent(), mMapRenderer->outputSize().width(), mMapRenderer->outputSize().height() ).results();
+ identifyResult = layer->dataProvider()->identify( *infoPoint, QgsRaster::IdentifyFormatValue, mMapRenderer->extent(), mMapRenderer->outputSize().width(), mMapRenderer->outputSize().height() );
}
+ if ( !identifyResult.isValid() )
+ return 1;
+
+ QMap<int, QVariant> attributes = identifyResult.results();
if ( infoFormat == "application/vnd.ogc.gml" )
{
QgsFeature feature;
diff --git a/tests/src/python/test_qgsexpression.py b/tests/src/python/test_qgsexpression.py
index bee50ab..b715ebf 100644
--- a/tests/src/python/test_qgsexpression.py
+++ b/tests/src/python/test_qgsexpression.py
@@ -41,6 +41,18 @@ class TestQgsExpressionCustomFunctions(unittest.TestCase):
def sqrt(values, feature, parent):
pass
+ @qgsfunction(1, 'testing', register=False)
+ def help_with_docstring(values, feature, parent):
+ """The help comes from the python docstring."""
+ pass
+
+ help_text = 'The help comes from a variable.'
+
+ @qgsfunction(1, 'testing', register=False, help_text=help_text)
+ def help_with_variable(values, feature, parent):
+ """This docstring is not used for the help."""
+ pass
+
@qgsfunction(1, 'testing', register=False, usesgeometry=True)
def geomtest(values, feature, parent):
pass
@@ -66,6 +78,17 @@ class TestQgsExpressionCustomFunctions(unittest.TestCase):
args = function.params()
self.assertEqual(args, 3)
+ def testHelp(self):
+ QgsExpression.registerFunction(self.help_with_variable)
+ html = ('<h3>help_with_variable function</h3><br>'
+ 'The help comes from a variable.')
+ self.assertEqual(self.help_with_variable.helptext(), html)
+
+ QgsExpression.registerFunction(self.help_with_docstring)
+ html = ('<h3>help_with_docstring function</h3><br>'
+ 'The help comes from the python docstring.')
+ self.assertEqual(self.help_with_docstring.helptext(), html)
+
def testAutoArgsAreExpanded(self):
function = self.expandargs
args = function.params()
@@ -186,5 +209,6 @@ class TestQgsExpressionCustomFunctions(unittest.TestCase):
result = exp.evaluate()
self.assertEqual(exp_res, result)
+
if __name__ == "__main__":
unittest.main()
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/qgis.git
More information about the Pkg-grass-devel
mailing list