Skip to content

Latest commit

 

History

History
27 lines (19 loc) · 1.81 KB

cardano-wallet-update.md

File metadata and controls

27 lines (19 loc) · 1.81 KB

Cluster launcher update

Plutip relies heavily on a local cluster testing framework from cardano-wallet. See Cardano.Wallet.Launch.Cluster module, and originally Cardano.Wallet.Shelley.Launch.Cluster@1952de1 (this is the one that is used in Plutip currently).

Initially, framework was used as-is, but in order to add ability to set slot length and epoch size to Plutip, module Cluster.hs was copied from cardano-wallet to Plutip's codebase and adjusted to make this settings possible. So in case of updating cardano-wallet dependency be sure that original Cluster.hs and Plutip's one differs only in expected way.

At the moment all changes are related to adding ExtraConfig to necessary ADTs and functions in Plutip's version of Cluster.hs and difference with the original is pretty small.

The Cardano.Wallet.Shelley.Launch.Cluster@1952de1 module was split into:

  1. Plutip.Launch.PoolConfigs
  2. Plutip.Launch.Cluster
  3. Plutip.Launch.FaucetFunds

All modified types and functions are marked with the "altered" comment for easier search, e.g.:

-- altered: `def :: ExtraConfig` added
localClusterConfigFromEnv :: IO LocalClusterConfig
localClusterConfigFromEnv = do
    era <- clusterEraFromEnv
    logConf <- logFileConfigFromEnv (Just $ clusterEraToString era)
    pure $ LocalClusterConfig defaultPoolConfigs era logConf def