Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
More minor cleanups
  • Loading branch information
nyalldawson committed May 3, 2023
1 parent 3651c8d commit 2e83566
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions python/plugins/processing/gui/Postprocessing.py
Expand Up @@ -19,7 +19,10 @@
__date__ = 'August 2012'
__copyright__ = '(C) 2012, Victor Olaya'

from typing import Dict
from typing import (
Dict,
Optional
)
import traceback


Expand Down Expand Up @@ -114,7 +117,7 @@ def post_process_layer(output_name: str,

def post_process_layer_tree_layer(layer_tree_layer: QgsLayerTreeLayer):
"""
Applies post processing steps to a QgsLayerTreeLayer created for
Applies post-processing steps to a QgsLayerTreeLayer created for
an algorithm's output
"""
layer = layer_tree_layer.layer()
Expand All @@ -123,7 +126,14 @@ def post_process_layer_tree_layer(layer_tree_layer: QgsLayerTreeLayer):
layer_tree_layer.setCustomProperty("showFeatureCount", True)


def handleAlgorithmResults(alg, context, feedback=None, showResults=True, parameters={}):
def handleAlgorithmResults(alg: QgsProcessingAlgorithm,
context: QgsProcessingContext,
feedback: Optional[QgsProcessingFeedback] = None,
showResults: bool = True,
parameters: Optional[Dict] = None):
if not parameters:
parameters = {}

wrongLayers = []
if feedback is None:
feedback = QgsProcessingFeedback()
Expand Down

0 comments on commit 2e83566

Please sign in to comment.