diff --git a/addons/mrp/models/stock_move.py b/addons/mrp/models/stock_move.py index 5cb92a5025c..2017b5d9490 100644 --- a/addons/mrp/models/stock_move.py +++ b/addons/mrp/models/stock_move.py @@ -33,7 +33,7 @@ class StockMoveLots(models.Model): def _check_lot_id(self): if self.move_id.product_id.tracking == 'serial': lots = set([]) - for move_lot in self.move_id.move_lot_ids.filtered(lambda r: not r.lot_produced_id): + for move_lot in self.move_id.move_lot_ids.filtered(lambda r: not r.lot_produced_id and r.lot_id): if move_lot.lot_id in lots: raise exceptions.UserError(_('You cannot use the same serial number in two different lines.')) if float_compare(move_lot.quantity_done, 1.0, precision_rounding=move_lot.product_id.uom_id.rounding) == 1: