Closed mmontin closed 1 week ago
This was used in the code for sure. I think this feature is light and can still come in handy.
There used to be 4 policies:
BalancingUtxosDatumless
Balance with UTxOs that have no datum and only ada. This was the default after PR #355. The current hardcoded override also has this behavior and I think it should remain the default policy.BalancingUtxosAll
Balance with all UTxOs. This was our legacy default which turned out to be annoying because it could spend UTxOs with some datum (which usually are UTxOs we plan to use for greater purpose later). I don't think we should have this anymore, it was only kept just in case as a way to roll back to the legacy balancing policy.BalancingUtxosWith
Balance with an explicit set of UTxOs: I think this is the most important option beside the default. Combined with prior utxo search, it makes it possible to choose in advance exactly which UTxOs we allow cooked to use during the balancing process.BalancingUtxosWithout
Balance with a blocklist of UTxOs that should be not be used: we could reinstate it but it is a bit redundant with the previous one, especially given the convenient utxo search framework we now have in cookedTo sum up, I would like to re-introduced a simpler version of this tx skeleton option with only 2 policies:
data BalancingUtxos
= -- | Use all UTxOs without datum
BalancingUtxosAutomatic
| -- | Use only the provided UTxOs
BalancingUtxosWith [TxOutRef]
Will be closed by #417
We used to have a mechanism to precisely select utxos eligible for balancing. It was merged here: #355 It was removed as part as the commit https://github.com/tweag/cooked-validators/commit/931d1b4353e4c8b740b8cc6b74b19f3d14a1b15a, in file Balancing.hs line 249. It was removed under the assumption that it was not actually used anywhere in the code. That assumption might have been wrong. We need to investigate it and restore this functionality if needed.