Skip to content

Version 4.0.0

Latest
Compare
Choose a tag to compare
@mmontin mmontin released this 28 Jun 14:05
· 41 commits to main since this release

Added

  • File IMPORTS to specify how modules should be imported and prefixed
  • Instaured a standard for naming imports, homogenized all modules accordingly
  • Default language extensions in package.yaml
  • A new set of tests Cooked.BasicUsageSpec to cover basic use cases
  • A new validate function validateTxSkel' that directly returns a list of utxos
  • An actual content to hie.yaml (automatically generated by gen-hie)
  • Support for collaterals in skeleton options, with three options: auto from
    first signer, auto from given wallet, or given set of utxos.
  • Top-level comments to all modules
  • currencySymbolFromLanguageAndMP to get the right Currency symbol based on a
    plutus version and a minting policy
  • setParams in MonadBlockChainWithoutValidation to account for future
    changes of parameters following votes.
  • txOptCollateralUtxos to control which utxos should be used as collaterals
  • Missing Eq instance for MockChainError
  • Full support in ShowBS for printing into bytestring the whole transaction
    context within on-chain code
  • validatorToTypedValidator which does what its name indicates
  • Adding support for PrettyCooked for TxLbl
  • A set of modules (in Conversion) that each defines a typeclass of elements
    that can be converted to a certain type. For example ToPubKeyHash or
    ToAddress.
  • New utxos searches vanillaOutputsAtSearch, scriptOutputsSearch,
    onlyValueOutputsAtSearch and referenceScriptOutputsSearch
  • A test file Cooked/BalancingSpec.hs that covers the new balancing mechanism
    extensively.
  • A new module Cooked/MockChain/MinAda.hs to separate min ada computation from
    the balancing mechanism.
  • A new documentation file doc/BALANCING.md that extensively describes the new
    balancing mechanism and the available options.
  • A new skeleton option to manage fees called FeePolicy. It makes it possible
    to successfully validate transactions that have not been automatically
    balanced.
  • Auto computation of total and return collaterals based on fees and protocol
    parameters now fully handled during balancing and transaction generation.
  • Two filters in Output.hs, isScriptOutput and isPKOutput
  • A new helper function to get the full output value of a skeleton,
    txSkelOutputsValue
  • Proposal procedures can now be issued and described in transaction
    skeletons. If they contain parameter changes or treasury withdrawals, a
    witness script can be attached and will be run.
  • TxSkelRedeemer is now used for all kinds of scripts.
  • File CONWAY to document which Conway features are currently
    supported.
  • A new option txOptAnchorResolution to decide whether to resolve urls
    locally or on the web (unsafe). The default is to resolve them locally with a
    given map from urls to page content as bytestring.

Removed

  • Extraneous dependencies in package.yaml
  • File Cooked.TestUtils, its content has been added to Cooked.MockChain.Testing
  • Support for importing scripts from bytestring in module Cooked.RawUPLC, to be
    added back later on
  • Deprecated skeleton option: txOptAwaitTxConfirmed
  • Deprecated use of * instead of Type
  • Many unused pragmas
  • Orphan default instance for Ledger.Slot
  • MintsRedeemer (replaced by TxSkelRedeemer)

Changed

  • Default era from Babbage to Conway
  • No longer rely on deprecated plutus-apps, but instead
    cardano-node-emulator
  • From GHC 8.10.4 to 9.6.5 and associated versions of HLS
  • Rely mostly on
    CHaP
    instead of direct git sources
  • Update the cheatsheet to account for various small changes + collaterals
  • ImportQualifiedPost by default
  • MockChainEnv is gone, replaced by the new mcstParams field in MockChainSt
  • The structure of the various steps around transaction validation (fee
    generation, ensuring min ada...)
  • Regrouped all important validation steps, including modifications requested in
    skeleton options in the direct implementation of validateTxSkel.
  • Homogenized and simplified the functions to generate transaction parts from a
    TxSkel by using a reader monad over various parameters.
  • Fully reworked the balancing process and associated balancing options.
    See in the dedicated documentation.
  • Reworked MockChain errors related to balancing.

Fixed

  • A bug where the ledger state would not be updated by consumed collaterals
  • A curious choice where parameter changes for single transactions would be
    applied several times instead of one
  • Various warnings around incomplete pattern matches when selecting utxos for
    balancing, with more suitable algorithms