PlutusCore.Parser.Builtin.conValue performs Value.fromList which is defined as
fromList :: [(K, [(K, Quantity)])] -> BuiltinResult Value
fromList xs = do
-- Use unchecked addition during construction
let outerMap =
Map.fromListWith
(Map.unionWith unsafeAddQuantity) -- combine inner maps with unchecked addition
(second (Map.fromListWith unsafeAddQuantity) <$> xs)
-- Validate all quantities are within bounds
pack <$> validateQuantities outerMap
i.e. does unsafeAddQuantity instead of what buildValueWith (the worker of the deserializer) does with Map.fromDistinctDescList and whatnot.
Just use buildValueWith consistently.
PlutusCore.Parser.Builtin.conValueperformsValue.fromListwhich is defined asi.e. does
unsafeAddQuantityinstead of whatbuildValueWith(the worker of the deserializer) does withMap.fromDistinctDescListand whatnot.Just use
buildValueWithconsistently.