Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[processing] More verbose error when unsupported SAGA version found
(cherry-picked from 16106b8)
  • Loading branch information
nyalldawson committed May 3, 2018
1 parent 8739547 commit 8175c4c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions python/plugins/processing/algs/saga/SagaAlgorithmProvider.py
Expand Up @@ -43,6 +43,8 @@
pluginPath = os.path.normpath(os.path.join(
os.path.split(os.path.dirname(__file__))[0], os.pardir))

REQUIRED_VERSION = '2.3.'


class SagaAlgorithmProvider(QgsProcessingProvider):

Expand Down Expand Up @@ -85,8 +87,8 @@ def loadAlgorithms(self):
self.tr('Processing'), Qgis.Critical)
return

if not version.startswith('2.3.'):
QgsMessageLog.logMessage(self.tr('Problem with SAGA installation: unsupported SAGA version found.'),
if not version.startswith(REQUIRED_VERSION):
QgsMessageLog.logMessage(self.tr('Problem with SAGA installation: unsupported SAGA version (found: {}, required: {}).').format(version, REQUIRED_VERSION),
self.tr('Processing'),
Qgis.Critical)
return
Expand Down

0 comments on commit 8175c4c

Please sign in to comment.