Skip to content

Commit a549ded

Browse files
committed
[processing] prevent circular dependencies in models
fixes #99090
1 parent b2a1273 commit a549ded

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

python/plugins/processing/modeler/ModelerDialog.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -164,10 +164,6 @@ def _mimeDataAlgorithm(items):
164164
self.btnEditHelp.setIcon(QIcon(os.path.join(pluginPath, 'images', 'edithelp.png')))
165165
self.btnRun.setIcon(QIcon(os.path.join(pluginPath, 'images', 'runalgorithm.png')))
166166

167-
# Fill trees with inputs and algorithms
168-
self.fillInputsTree()
169-
self.fillAlgorithmTree()
170-
171167
if hasattr(self.searchBox, 'setPlaceholderText'):
172168
self.searchBox.setPlaceholderText(self.tr('Search...'))
173169
if hasattr(self.textName, 'setPlaceholderText'):
@@ -198,6 +194,9 @@ def _mimeDataAlgorithm(items):
198194
self.alg = ModelerAlgorithm()
199195
self.alg.modelerdialog = self
200196

197+
self.fillInputsTree()
198+
self.fillAlgorithmTree()
199+
201200
self.view.centerOn(0, 0)
202201
self.alg.setModelerView(self)
203202
self.help = None
@@ -484,6 +483,8 @@ def fillAlgorithmTreeUsingProviders(self):
484483
for alg in algs:
485484
if not alg.showInModeler or alg.allowOnlyOpenedLayers:
486485
continue
486+
if alg.commandLineName() == self.alg.commandLineName():
487+
continue
487488
if text == '' or text.lower() in alg.name.lower():
488489
if alg.group in groups:
489490
groupItem = groups[alg.group]

0 commit comments

Comments
 (0)