From c823ca38a92ee70001b9bddb2abd6b2b9b5b7c06 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 7 Jan 2026 08:29:45 +0100 Subject: [PATCH] Use only production inputs or outputs for lot trace The production moves can not have any other traces than their sibling moves. Closes #14385 --- modules/production/stock.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/modules/production/stock.py b/modules/production/stock.py index c81e8e83ff..9ef1025a28 100644 --- a/modules/production/stock.py +++ b/modules/production/stock.py @@ -206,13 +206,15 @@ class LotTrace(metaclass=PoolMeta): else_=document) def _get_upward_traces(self): - traces = super()._get_upward_traces() if self.production_input: - traces.update(self.production_input.outputs) + traces = set(self.production_input.outputs) + else: + traces = super()._get_upward_traces() return traces def _get_downward_traces(self): - traces = super()._get_downward_traces() if self.production_output: - traces.update(self.production_output.inputs) + traces = set(self.production_output.inputs) + else: + traces = super()._get_downward_traces() return traces