diff --git a/Makefile b/Makefile index a2a17e7..90ae380 100644 --- a/Makefile +++ b/Makefile @@ -12,6 +12,7 @@ usage: @echo " haddock -- Generate Haddock docs for project" hoogle: + pkill hoogle || true hoogle generate --local=haddock --database=hoo/local.hoo hoogle server --local -p 8081 >> /dev/null & hoogle server --local --database=hoo/local.hoo -p 8082 >> /dev/null & diff --git a/agora-test/Spec.hs b/agora-test/Spec.hs index 502cb27..6442ae8 100644 --- a/agora-test/Spec.hs +++ b/agora-test/Spec.hs @@ -11,7 +11,7 @@ import Test.Tasty (defaultMain, testGroup) import Spec.Model.MultiSig qualified as MultiSig import Spec.Stake qualified as Stake --- | The Agora test suite +-- | The Agora test suite. main :: IO () main = defaultMain $ diff --git a/agora-test/Spec/Model/MultiSig.hs b/agora-test/Spec/Model/MultiSig.hs index 15dcfae..397d49d 100644 --- a/agora-test/Spec/Model/MultiSig.hs +++ b/agora-test/Spec/Model/MultiSig.hs @@ -53,7 +53,7 @@ import Apropos ( import Apropos.Gen (Gen, choice, int, linear, list) import Apropos.LogicalModel (Enumerable) import Apropos.LogicalModel.Enumerable (Enumerable (enumerated)) -import Apropos.Script (HasScriptRunner (expect, runScriptTestsWhere, script)) +import Apropos.Script (ScriptModel (expect, runScriptTestsWhere, script)) import Test.Tasty (TestTree, testGroup) import Test.Tasty.Hedgehog (fromGroup) @@ -157,7 +157,7 @@ instance HasParameterisedGenerator MultiSigProp MultiSigModel where -- Return the generated model. pure (MultiSigModel msig ctx) -instance HasScriptRunner MultiSigProp MultiSigModel where +instance ScriptModel MultiSigProp MultiSigModel where -- When the script runs, we want the model to meet the minimum signatures. expect :: (MultiSigModel :+ MultiSigProp) -> Formula MultiSigProp expect Apropos = Var MeetsMinSigs @@ -171,7 +171,7 @@ instance HasScriptRunner MultiSigProp MultiSigModel where (pcon PUnit) perror --- | Consistency tests for the 'HasParameterisedGenerator' instance of 'MultiSigModel' +-- | Consistency tests for the 'HasParameterisedGenerator' instance of 'MultiSigModel'. genTests :: TestTree genTests = testGroup "genTests" $ @@ -182,7 +182,7 @@ genTests = Yes ] --- | Tests for the 'HasScriptRunner' instance of 'MultiSigModel' +-- | Tests for the 'ScriptModel' instance of 'MultiSigModel'. plutarchTests :: TestTree plutarchTests = testGroup "plutarchTests" $ diff --git a/agora-test/Spec/Sample/Stake.hs b/agora-test/Spec/Sample/Stake.hs index 4bb0073..85b95ac 100644 --- a/agora-test/Spec/Sample/Stake.hs +++ b/agora-test/Spec/Sample/Stake.hs @@ -21,7 +21,6 @@ module Spec.Sample.Stake ( ) where -------------------------------------------------------------------------------- - import Plutarch.Api.V1 ( mintingPolicySymbol, mkMintingPolicy, @@ -47,7 +46,7 @@ import Plutus.V1.Ledger.Api ( import Plutus.V1.Ledger.Contexts (TxOut (TxOut), TxOutRef (TxOutRef)) import Plutus.V1.Ledger.Interval qualified as Interval import Plutus.V1.Ledger.Scripts (Validator) -import Plutus.V1.Ledger.Value (TokenName (TokenName)) +import Plutus.V1.Ledger.Value (AssetClass (AssetClass), TokenName (TokenName)) import Plutus.V1.Ledger.Value qualified as Value -------------------------------------------------------------------------------- @@ -59,8 +58,17 @@ import Spec.Util (datumPair, toDatumHash) -------------------------------------------------------------------------------- -- | 'Stake' parameters for 'LQ'. -stake :: Stake LQ -stake = Stake +stake :: Stake +stake = + Stake + { gtClassRef = + AssetClassRef + ( AssetClass + ( "da8c30857834c6ae7203935b89278c532b3995245295456f993e1d24" + , "LQ" + ) + ) + } -- | 'Stake' policy instance. policy :: MintingPolicy @@ -135,9 +143,9 @@ stakeCreationUnsigned = -- | Config for creating a ScriptContext that deposits or withdraws. data DepositWithdrawExample = DepositWithdrawExample - { startAmount :: Integer + { startAmount :: Discrete GTTag -- ^ The amount of GT stored before the transaction. - , delta :: Integer + , delta :: Discrete GTTag -- ^ The amount of GT deposited or withdrawn from the Stake. } @@ -160,10 +168,7 @@ stakeDepositWithdraw config = { txOutAddress = Address (ScriptCredential $ validatorHash validator) Nothing , txOutValue = st - <> Value.singleton - "da8c30857834c6ae7203935b89278c532b3995245295456f993e1d24" - "LQ" - stakeBefore.stakedAmount + <> discreteValue stake.gtClassRef stakeBefore.stakedAmount , txOutDatumHash = Just (toDatumHash stakeAfter) } ] @@ -172,10 +177,7 @@ stakeDepositWithdraw config = { txOutAddress = Address (ScriptCredential $ validatorHash validator) Nothing , txOutValue = st - <> Value.singleton - "da8c30857834c6ae7203935b89278c532b3995245295456f993e1d24" - "LQ" - stakeAfter.stakedAmount + <> discreteValue stake.gtClassRef stakeAfter.stakedAmount , txOutDatumHash = Just (toDatumHash stakeAfter) } ] diff --git a/agora-test/Spec/Stake.hs b/agora-test/Spec/Stake.hs index 8064ddf..ccd16e7 100644 --- a/agora-test/Spec/Stake.hs +++ b/agora-test/Spec/Stake.hs @@ -1,3 +1,5 @@ +{-# LANGUAGE QuasiQuotes #-} + {- | Module : Spec.Stake Maintainer : emi@haskell.fyi @@ -27,7 +29,7 @@ import Spec.Util (policyFailsWith, policySucceedsWith, toDatum, validatorFailsWi -------------------------------------------------------------------------------- --- | Stake tests +-- | Stake tests. tests :: [TestTree] tests = [ testGroup @@ -57,13 +59,13 @@ tests = "stakeDepositWithdraw withdraw" (stakeValidator Stake.stake) (toDatum $ StakeDatum 100_000 signer) - (toDatum $ DepositWithdraw (negate 100_000)) + (toDatum $ DepositWithdraw $ negate 100_000) (Stake.stakeDepositWithdraw $ DepositWithdrawExample {startAmount = 100_000, delta = negate 100_000}) , validatorFailsWith "stakeDepositWithdraw negative GT" (stakeValidator Stake.stake) (toDatum $ StakeDatum 100_000 signer) - (toDatum $ DepositWithdraw (negate 1_000_000)) + (toDatum $ DepositWithdraw 1_000_000) (Stake.stakeDepositWithdraw $ DepositWithdrawExample {startAmount = 100_000, delta = negate 1_000_000}) ] ] diff --git a/agora.cabal b/agora.cabal index b50a55b..3afdca4 100644 --- a/agora.cabal +++ b/agora.cabal @@ -96,6 +96,7 @@ common deps , generics-sop , plutarch , plutarch-extra + , plutarch-numeric , plutus-core , plutus-ledger-api , plutus-tx @@ -108,6 +109,7 @@ common deps common test-deps build-depends: + , apropos , apropos-tx , QuickCheck , quickcheck-instances @@ -121,10 +123,11 @@ library Agora.AuthorityToken Agora.MultiSig Agora.SafeMoney - Agora.SafeMoney.QQ Agora.Stake + Agora.Effect Agora.Treasury - Agora.Voting + Agora.Governor + Agora.Proposal other-modules: Agora.Utils diff --git a/agora/Agora/Effect.hs b/agora/Agora/Effect.hs new file mode 100644 index 0000000..82764d2 --- /dev/null +++ b/agora/Agora/Effect.hs @@ -0,0 +1,37 @@ +{- | +Module : Agora.Effect +Maintainer : emi@haskell.fyi +Description: Helpers for constructing effects + +Helpers for constructing effects. +-} +module Agora.Effect (makeEffect) where + +import Plutarch.Api.V1 (PScriptPurpose (PSpending), PTxInfo, PTxOutRef, PValidator) +import Plutarch.Internal (punsafeCoerce) +import Plutarch.Monadic qualified as P + +-------------------------------------------------------------------------------- + +-- | Helper "template" for creating effect validator. +makeEffect :: + forall (datum :: PType) (s :: S). + PIsData datum => + (Term s datum -> Term s PTxOutRef -> Term s PTxInfo -> Term s POpaque) -> + Term s PValidator +makeEffect f = + plam $ \datum _redeemer ctx' -> P.do + ctx <- pletFields @'["txInfo", "purpose"] ctx' + txInfo' <- plet ctx.txInfo + + let datum' :: Term _ datum + datum' = pfromData $ punsafeCoerce datum + + PSpending txOutRef <- pmatch $ pfromData ctx.purpose + txOutRef' <- plet (pfield @"_0" # txOutRef) + + -- TODO: Here, check that a *single* GAT is burned. + + f datum' txOutRef' txInfo' + +-------------------------------------------------------------------------------- diff --git a/agora/Agora/Governor.hs b/agora/Agora/Governor.hs new file mode 100644 index 0000000..33584e1 --- /dev/null +++ b/agora/Agora/Governor.hs @@ -0,0 +1,33 @@ +{- | +Module : Agora.Governor +Maintainer : emi@haskell.fyi +Description: Governor entity scripts acting as authority of entire system. + +Governor entity scripts acting as authority of entire system. +-} +module Agora.Governor (GovernorDatum (..), GovernorRedeemer (..), Governor (..)) where + +import Agora.Proposal (ProposalThresholds) + +-- | Datum for the Governor script. +newtype GovernorDatum = GovernorDatum + { proposalThresholds :: ProposalThresholds + -- ^ Gets copied over upon creation of a 'Agora.Proposal.ProposalDatum'. + } + +{- | Redeemer for Governor script. The governor has two primary + responsibilities: + + 1. The gating of Proposal creation. + 2. The gating of minting authority tokens. +-} +data GovernorRedeemer + = -- | Checks that a proposal was created lawfully, and allows it. + CreateProposal + | -- | Checks that a SINGLE proposal finished correctly, + -- and allows minting GATs for each effect script. + MintGATs + +-- | Parameters for creating Governor scripts. +data Governor + = Governor diff --git a/agora/Agora/MultiSig.hs b/agora/Agora/MultiSig.hs index 6e8270d..93cf3e6 100644 --- a/agora/Agora/MultiSig.hs +++ b/agora/Agora/MultiSig.hs @@ -77,13 +77,13 @@ deriving via (DerivePConstantViaData MultiSig PMultiSig) instance (PConstant Mul -------------------------------------------------------------------------------- --- | Check if a Haskell-level MultiSig signs this transaction +-- | Check if a Haskell-level MultiSig signs this transaction. validatedByMultisig :: MultiSig -> Term s (PTxInfo :--> PBool) validatedByMultisig params = phoistAcyclic $ pvalidatedByMultisig # pconstant params --- | Check if a Plutarch-level MultiSig signs this transaction +-- | Check if a Plutarch-level MultiSig signs this transaction. pvalidatedByMultisig :: Term s (PMultiSig :--> PTxInfo :--> PBool) pvalidatedByMultisig = phoistAcyclic $ diff --git a/agora/Agora/Proposal.hs b/agora/Agora/Proposal.hs new file mode 100644 index 0000000..ddad144 --- /dev/null +++ b/agora/Agora/Proposal.hs @@ -0,0 +1,208 @@ +{-# LANGUAGE TemplateHaskell #-} + +{- | +Module : Agora.Proposal +Maintainer : emi@haskell.fyi +Description: Proposal scripts encoding effects that operate on the system. + +Proposal scripts encoding effects that operate on the system. +-} +module Agora.Proposal ( + -- * Haskell-land + Proposal (..), + ProposalDatum (..), + ProposalStatus (..), + ProposalThresholds (..), + ProposalVotes (..), + ResultTag (..), + + -- * Plutarch-land + PProposalDatum (..), + PResultTag (..), +) where + +import GHC.Generics qualified as GHC +import Generics.SOP (Generic, I (I)) +import Plutarch.Api.V1 ( + PDatumHash, + PMap, + PPubKeyHash, + PValidatorHash, + ) +import Plutarch.DataRepr ( + PDataFields, + PIsDataReprInstances (PIsDataReprInstances), + ) +import Plutus.V1.Ledger.Api (DatumHash, PubKeyHash, ValidatorHash) +import PlutusTx qualified + +-------------------------------------------------------------------------------- + +import Agora.SafeMoney (Discrete, GTTag, PDiscrete) + +-------------------------------------------------------------------------------- +-- Haskell-land + +{- | Encodes a result. Typically, for a Yes/No proposal, we encode it like this: + +@ +"No" ~ 'ResultTag' 0 +"Yes" ~ 'ResultTag' 1 +@ +-} +newtype ResultTag = ResultTag {getResultTag :: Integer} + deriving stock (Eq, Show) + deriving newtype (PlutusTx.ToData, PlutusTx.FromData, PlutusTx.UnsafeFromData) + +{- | The "status" of the proposal. This is only useful for state transitions, + as opposed to time-based "phases". + + If the proposal is 'VotingReady', for instance, that doesn't necessarily + mean that voting is possible, as this also requires the timing to be right. +-} +data ProposalStatus + = -- | A draft proposal represents a proposal that has yet to be realized. + -- + -- In effect, this means one which didn't have enough LQ to be a full + -- proposal, and needs cosigners to enable that to happen. This is + -- similar to a "temperature check", but only useful if multiple people + -- want to pool governance tokens together. If the proposal doesn't get to + -- 'VotingReady' on time, the proposal will __never__ be able to get + -- voted on. + Draft + | -- | The proposal has/had enough GT cosigned in order to be a fully fledged + -- proposal. + -- + -- This means that once the timing requirements align, + -- proposal will be able to be voted on. + VotingReady + | -- | The proposal has finished. + -- + -- This can mean it's been voted on and completed, but it can also mean + -- the proposal failed due to time constraints or didn't + -- get to 'VotingReady' first. + -- + -- TODO: The owner of the proposal may choose to reclaim their proposal. + Finished + +PlutusTx.makeIsDataIndexed ''ProposalStatus [('Draft, 0), ('VotingReady, 1), ('Finished, 2)] + +{- | The threshold values for various state transitions to happen. + This data is stored centrally (in the 'Agora.Governor.Governor') and copied over + to 'Proposal's when they are created. +-} +data ProposalThresholds = ProposalThresholds + { execute :: Discrete GTTag + -- ^ How much GT minimum must a particular 'ResultTag' accumulate for it to pass. + , draft :: Discrete GTTag + -- ^ How much GT required to "create" a proposal. + , vote :: Discrete GTTag + -- ^ How much GT required to allow voting to happen. + -- (i.e. to move into 'VotingReady') + } + +PlutusTx.makeIsDataIndexed ''ProposalThresholds [('ProposalThresholds, 0)] + +{- | Map which encodes the total tally for each result. + It's important that the "shape" is consistent with the shape of 'effects'. + + e.g. if the 'effects' field looks like the following: + + @[('ResultTag' 0, []), ('ResultTag' 1, [(vh, dh)])]@ + + Then 'ProposalVotes' needs be of the shape: + + @[('ResultTag' 0, n), ('ResultTag' 1, m)]@ +-} +newtype ProposalVotes = ProposalVotes + { getProposalVotes :: [(ResultTag, Integer)] + } + deriving newtype (PlutusTx.ToData, PlutusTx.FromData, PlutusTx.UnsafeFromData) + +-- | Haskell-level datum for Proposal scripts. +data ProposalDatum = ProposalDatum + { -- TODO: could we encode this more efficiently? + -- This is shaped this way for future proofing. + -- See https://github.com/Liqwid-Labs/agora/issues/39 + effects :: [(ResultTag, [(ValidatorHash, DatumHash)])] + -- ^ Effect lookup table. First by result, then by effect hash. + , status :: ProposalStatus + -- ^ The status the proposal is in. + , cosigners :: [PubKeyHash] + -- ^ Who created the proposal initially, and who cosigned it later. + , thresholds :: ProposalThresholds + -- ^ Thresholds copied over on initialization. + , votes :: ProposalVotes + -- ^ Vote tally on the proposal + } + +PlutusTx.makeIsDataIndexed ''ProposalDatum [('ProposalDatum, 0)] + +-- | Parameters that identify the Proposal validator script. +data Proposal = Proposal + +-------------------------------------------------------------------------------- +-- Plutarch-land + +-- | Plutarch-level version of 'ResultTag'. +newtype PResultTag (s :: S) = PResultTag (Term s PInteger) + deriving (PlutusType, PIsData, PEq, POrd) via (DerivePNewtype PResultTag PInteger) + +-- | Plutarch-level version of 'ProposalStatus'. +data PProposalStatus (s :: S) + = -- TODO: 'PProposalStatus' ought te be encoded as 'PInteger'. + -- e.g. like Tilde used 'pmatchEnum'. + PDraft (Term s (PDataRecord '[])) + | PVotingReady (Term s (PDataRecord '[])) + | PFinished (Term s (PDataRecord '[])) + deriving stock (GHC.Generic) + deriving anyclass (Generic) + deriving anyclass (PIsDataRepr) + deriving + (PlutusType, PIsData) + via PIsDataReprInstances PProposalStatus + +-- | Plutarch-level version of 'ProposalThresholds'. +newtype PProposalThresholds (s :: S) = PProposalThresholds + { getProposalThresholds :: + Term + s + ( PDataRecord + '[ "execute" ':= PDiscrete GTTag + , "draft" ':= PDiscrete GTTag + , "vote" ':= PDiscrete GTTag + ] + ) + } + deriving stock (GHC.Generic) + deriving anyclass (Generic) + deriving anyclass (PIsDataRepr) + deriving + (PlutusType, PIsData, PDataFields) + via (PIsDataReprInstances PProposalThresholds) + +-- | Plutarch-level version of 'ProposalVotes'. +newtype PProposalVotes (s :: S) + = PProposalVotes (Term s (PMap PResultTag PInteger)) + deriving (PlutusType, PIsData) via (DerivePNewtype PProposalVotes (PMap PResultTag PInteger)) + +-- | Plutarch-level version of 'ProposalDatum'. +newtype PProposalDatum (s :: S) = PProposalDatum + { getProposalDatum :: + Term + s + ( PDataRecord + '[ "effects" ':= PMap PResultTag (PMap PValidatorHash PDatumHash) + , "status" ':= PProposalStatus + , "cosigners" ':= PBuiltinList PPubKeyHash + , "thresholds" ':= PProposalThresholds + , "votes" ':= PProposalVotes + ] + ) + } + deriving stock (GHC.Generic) + deriving anyclass (Generic) + deriving anyclass (PIsDataRepr) + deriving + (PlutusType, PIsData, PDataFields) + via (PIsDataReprInstances PProposalDatum) diff --git a/agora/Agora/SafeMoney.hs b/agora/Agora/SafeMoney.hs index bec07c5..d8c3da0 100644 --- a/agora/Agora/SafeMoney.hs +++ b/agora/Agora/SafeMoney.hs @@ -7,8 +7,14 @@ Phantom-type protected types for handling money in Plutus. -} module Agora.SafeMoney ( -- * Types - MoneyClass, - PDiscrete, + PDiscrete (..), + Discrete (..), + + -- * Tags and refs + AssetClassRef (..), + ADATag, + GTTag, + adaRef, -- * Utility functions paddDiscrete, @@ -18,24 +24,17 @@ module Agora.SafeMoney ( -- * Conversions pdiscreteValue, pvalueDiscrete, - - -- * Example MoneyClasses - LQ, - ADA, + discreteValue, ) where -import Data.Proxy (Proxy (Proxy)) -import Data.String -import GHC.TypeLits ( - KnownSymbol, - Nat, - Symbol, - symbolVal, - ) import Prelude -------------------------------------------------------------------------------- +import Plutus.V1.Ledger.Value (AssetClass (AssetClass), Value) +import Plutus.V1.Ledger.Value qualified as Value +import PlutusTx qualified + import Plutarch.Api.V1 (PValue) import Plutarch.Builtin () import Plutarch.Internal () @@ -43,39 +42,66 @@ import Plutarch.Monadic qualified as P -------------------------------------------------------------------------------- -import Agora.Utils (passetClassValueOf, psingletonValue) +import Agora.Utils ( + passetClassValueOf', + psingletonValue, + ) + +-------------------------------------------------------------------------------- +-- Example tags + +-- | Governance token. +data GTTag + +-- | ADA. +data ADATag -------------------------------------------------------------------------------- --- | Type-level unique identifier for an 'Plutus.V1.Ledger.Value.AssetClass' -type MoneyClass = - ( -- AssetClass - Symbol - , -- TokenName - Symbol - , -- Decimal places - Nat - ) +-- | A tagged AssetClass. Use to resolve a reference inside of a PDiscrete +newtype AssetClassRef (tag :: Type) = AssetClassRef {getAssetClass :: AssetClass} --- | A 'PDiscrete' amount of currency tagged on the type level with the 'MoneyClass' it belongs to -newtype PDiscrete (mc :: MoneyClass) (s :: S) +-- | Resolves ada tags. +adaRef :: AssetClassRef ADATag +adaRef = AssetClassRef (AssetClass ("", "")) + +-- TODO: Currently it's possible to transmute from one discrete to another. +-- How do we prevent this? +-- +-- @ +-- transmute :: forall (a :: Type) (b :: Type). Discrete a -> Discrete b +-- transmute = Discrete . getDiscrete +-- @ + +{- | Represents a single asset in a 'Plutus.V1.Ledger.Value.Value' related to a particular 'AssetClass' + through 'AssetClassRef'. +-} +newtype Discrete (tag :: Type) = Discrete {getDiscrete :: Integer} + deriving stock (Show, Eq) + deriving newtype (PlutusTx.ToData, PlutusTx.FromData, PlutusTx.UnsafeFromData) + deriving newtype (Num) -- TODO: Use plutarch-numeric + +{- | Represents a single asset in a 'PValue' related to a particular 'AssetClass' + through 'AssetClassRef'. +-} +newtype PDiscrete (tag :: Type) (s :: S) = PDiscrete (Term s PInteger) - deriving (PlutusType, PIsData, PEq, POrd) via (DerivePNewtype (PDiscrete mc) PInteger) + deriving (PlutusType, PIsData, PEq, POrd) via (DerivePNewtype (PDiscrete tag) PInteger) -- | Check if one 'PDiscrete' is greater than another. -pgeqDiscrete :: forall (mc :: MoneyClass) (s :: S). Term s (PDiscrete mc :--> PDiscrete mc :--> PBool) +pgeqDiscrete :: forall (tag :: Type) (s :: S). Term s (PDiscrete tag :--> PDiscrete tag :--> PBool) pgeqDiscrete = phoistAcyclic $ plam $ \x y -> P.do PDiscrete x' <- pmatch x PDiscrete y' <- pmatch y y' #<= x' --- | Returns a zero-value 'PDiscrete' unit for any 'MoneyClass'. -pzeroDiscrete :: forall (mc :: MoneyClass) (s :: S). Term s (PDiscrete mc) +-- | Returns a zero-value 'PDiscrete' unit for any tag. +pzeroDiscrete :: forall (tag :: Type) (s :: S). Term s (PDiscrete tag) pzeroDiscrete = phoistAcyclic $ pcon (PDiscrete 0) --- | Add two 'PDiscrete' values of the same 'MoneyClass'. -paddDiscrete :: Term s (PDiscrete mc :--> PDiscrete mc :--> PDiscrete mc) +-- | Add two 'PDiscrete' values of the same tag. +paddDiscrete :: forall (tag :: Type) (s :: S). Term s (PDiscrete tag :--> PDiscrete tag :--> PDiscrete tag) paddDiscrete = phoistAcyclic $ -- In the future, this should use plutarch-numeric plam $ \x y -> P.do @@ -83,46 +109,38 @@ paddDiscrete = phoistAcyclic $ PDiscrete y' <- pmatch y pcon (PDiscrete $ x' + y') --- | The MoneyClass of LQ. -type LQ :: MoneyClass -type LQ = '("da8c30857834c6ae7203935b89278c532b3995245295456f993e1d24", "LQ", 6) - --- | The MoneyClass of ADA. -type ADA :: MoneyClass -type ADA = '("", "", 6) - -------------------------------------------------------------------------------- -- | Downcast a `PValue` to a `PDiscrete` unit. pvalueDiscrete :: - forall (moneyClass :: MoneyClass) (ac :: Symbol) (n :: Symbol) (scale :: Nat) s. - ( KnownSymbol ac - , KnownSymbol n - , moneyClass ~ '(ac, n, scale) - ) => - Term s (PValue :--> PDiscrete moneyClass) -pvalueDiscrete = phoistAcyclic $ + forall (tag :: Type) (s :: S). + AssetClassRef tag -> + Term s (PValue :--> PDiscrete tag) +pvalueDiscrete (AssetClassRef ac) = phoistAcyclic $ plam $ \f -> - pcon . PDiscrete $ - passetClassValueOf # pconstant (fromString $ symbolVal $ Proxy @ac) - # pconstant (fromString $ symbolVal $ Proxy @n) - # f + pcon . PDiscrete $ passetClassValueOf' ac # f {- | Get a `PValue` from a `PDiscrete`. __NOTE__: `pdiscreteValue` after `pvalueDiscrete` is not a round-trip. - It filters for a particular 'MoneyClass'. + It filters for a particular tag. -} pdiscreteValue :: - forall (moneyClass :: MoneyClass) (ac :: Symbol) (n :: Symbol) (scale :: Nat) s. - ( KnownSymbol ac - , KnownSymbol n - , moneyClass ~ '(ac, n, scale) - ) => - Term s (PDiscrete moneyClass :--> PValue) -pdiscreteValue = phoistAcyclic $ + forall (tag :: Type) (s :: S). + AssetClassRef tag -> + Term s (PDiscrete tag :--> PValue) +pdiscreteValue (AssetClassRef (AssetClass (cs, tn))) = phoistAcyclic $ plam $ \f -> pmatch f $ \case PDiscrete p -> psingletonValue - # pconstant (fromString $ symbolVal $ Proxy @ac) - # pconstant (fromString $ symbolVal $ Proxy @n) + # pconstant cs + # pconstant tn # p + +-- | Get a `Value` from a `Discrete`. +discreteValue :: + forall (tag :: Type). + AssetClassRef tag -> + Discrete tag -> + Value +discreteValue (AssetClassRef (AssetClass (cs, tn))) (Discrete v) = + Value.singleton cs tn v diff --git a/agora/Agora/SafeMoney/QQ.hs b/agora/Agora/SafeMoney/QQ.hs deleted file mode 100644 index 3fdf161..0000000 --- a/agora/Agora/SafeMoney/QQ.hs +++ /dev/null @@ -1,96 +0,0 @@ -{-# LANGUAGE TemplateHaskell #-} - -{- | -Module : Agora.SafeMoney.QQ -Maintainer : emi@haskell.fyi -Description: Quasiquoter for SafeMoney types. - -Quasiquoter for SafeMoney types. --} -module Agora.SafeMoney.QQ (discrete) where - -import GHC.Real (Ratio ((:%))) -import Language.Haskell.TH qualified as TH (Type) -import Language.Haskell.TH.Quote (QuasiQuoter (QuasiQuoter)) -import Language.Haskell.TH.Syntax ( - Dec (TySynD), - Exp (AppE, AppTypeE, LitE, VarE), - Info (TyConI), - Lit (IntegerL), - Pat, - Q, - TyLit (NumTyLit, StrTyLit), - Type (AppT, ConT, LitT, PromotedTupleT), - lookupTypeName, - reify, - ) -import Text.ParserCombinators.ReadP (readP_to_S, skipSpaces) -import Text.Read (lexP, readPrec_to_P) -import Text.Read.Lex (Lexeme (Ident, Number), Number, numberToFixed, numberToRational) -import Prelude - --------------------------------------------------------------------------------- - -import Plutarch.Internal (punsafeCoerce) - -import Agora.SafeMoney (MoneyClass, PDiscrete) - --------------------------------------------------------------------------------- - -{- | Generate 'PDiscrete' values tagged by a particular MoneyClass - -@ - [discrete| 123.456 'Agora.SafeMoney.ADA' |] :: 'Term' s ('PDiscrete' 'Agora.SafeMoney.ADA') -@ --} -discrete :: QuasiQuoter -discrete = QuasiQuoter discreteExp errorDiscretePat errorDiscreteType errorDiscreteDiscretelaration - -discreteConstant :: forall (moneyClass :: MoneyClass) s. Integer -> Term s (PDiscrete moneyClass) -discreteConstant n = punsafeCoerce (pconstant n :: Term s PInteger) - -fixedToInteger :: Integer -> (Integer, Integer) -> Integer -fixedToInteger places (i, f) = i * 10 ^ places + f - -safeIntegerUpcast :: Integer -> Number -> Either String Integer -safeIntegerUpcast places num = - case (numberToFixed places num, numberToRational num * 10 ^ places) of - (Just (i, f), _n :% 1) -> - Right $ fixedToInteger places (i, f) - (Just (i, f), _n :% _d) -> - Left $ "Using more than the available decimal places (" <> show places <> "). Would round to " <> show i <> "." <> show f - _ -> Left "Some error occurred while getting number" - -discreteExp :: String -> Q Exp -discreteExp s = case parseDiscreteRatioExp s of - Nothing -> - fail $ "Input malformed. Got: " <> s - Just (num, mc) -> do - mcName <- - lookupTypeName mc >>= \case - Nothing -> fail $ "MoneyClass with the name " <> show mc <> " is not in scope." - Just v -> pure v - reified <- reify mcName - case reified of - TyConI (TySynD tyName [] (AppT (AppT (AppT (PromotedTupleT 3) (LitT (StrTyLit _))) (LitT _)) (LitT (NumTyLit n)))) -> - case safeIntegerUpcast n num of - Right i -> - pure $ AppE (AppTypeE (VarE 'discreteConstant) (ConT tyName)) (LitE (IntegerL i)) - Left e -> fail e - ty' -> fail $ "Could not reify type, got: " <> show ty' - -parseDiscreteRatioExp :: String -> Maybe (Number, String) -parseDiscreteRatioExp s = - let p = skipSpaces *> ((,) <$> readPrec_to_P lexP 0 <* skipSpaces <*> readPrec_to_P lexP 0) <* skipSpaces - in case readP_to_S p s of - [((Number n, Ident i), "")] -> Just (n, i) - _ -> Nothing - -errorDiscretePat :: String -> Q Pat -errorDiscretePat _ = fail "Cannot use 'discrete' in a pattern context." - -errorDiscreteType :: String -> Q TH.Type -errorDiscreteType _ = fail "Cannot use 'discrete' in a type context." - -errorDiscreteDiscretelaration :: String -> Q [Dec] -errorDiscreteDiscretelaration _ = fail "Cannot use 'discrete' in a declaration context." diff --git a/agora/Agora/Stake.hs b/agora/Agora/Stake.hs index 3929449..67184bf 100644 --- a/agora/Agora/Stake.hs +++ b/agora/Agora/Stake.hs @@ -20,13 +20,7 @@ module Agora.Stake ( -------------------------------------------------------------------------------- -import Data.Proxy (Proxy (Proxy)) -import Data.String (IsString (fromString)) import GHC.Generics qualified as GHC -import GHC.TypeLits ( - KnownSymbol, - symbolVal, - ) import Generics.SOP (Generic, I (I)) import Prelude @@ -59,7 +53,9 @@ import Plutus.V1.Ledger.Value (AssetClass (AssetClass)) -------------------------------------------------------------------------------- import Agora.SafeMoney ( - MoneyClass, + AssetClassRef (..), + Discrete, + GTTag, PDiscrete, paddDiscrete, pdiscreteValue, @@ -71,6 +67,7 @@ import Agora.Utils ( anyOutput, paddValue, passert, + passetClassValueOf', pfindTxInByTxOutRef, pgeqByClass, pgeqByClass', @@ -84,12 +81,15 @@ import Agora.Utils ( -------------------------------------------------------------------------------- -- | Parameters for creating Stake scripts. -data Stake (gt :: MoneyClass) = Stake +newtype Stake = Stake + { gtClassRef :: AssetClassRef GTTag + -- ^ Used when inlining the AssetClass of a 'PDiscrete' in the script code. + } -- | Plutarch-level redeemer for Stake scripts. -data PStakeRedeemer (gt :: MoneyClass) (s :: S) +data PStakeRedeemer (s :: S) = -- | Deposit or withdraw a discrete amount of the staked governance token. - PDepositWithdraw (Term s (PDataRecord '["delta" ':= PDiscrete gt])) + PDepositWithdraw (Term s (PDataRecord '["delta" ':= PDiscrete GTTag])) | -- | Destroy a stake, retrieving its LQ, the minimum ADA and any other assets. PDestroy (Term s (PDataRecord '[])) deriving stock (GHC.Generic) @@ -97,18 +97,12 @@ data PStakeRedeemer (gt :: MoneyClass) (s :: S) deriving anyclass (PIsDataRepr) deriving (PlutusType, PIsData) - via PIsDataReprInstances (PStakeRedeemer gt) - --- FIXME: 'StakeRedeemer' and 'StakeDatum' are stripped of their --- typesafe `PDiscrete` equivalent due to issues with `makeIsDataIndexed` --- when using the kind @gt :: MoneyClass@. This ought to be fixed with --- a future patch in Plutarch upstream. For now, we will deal with lower --- type safety off-chain. + via PIsDataReprInstances PStakeRedeemer -- | Haskell-level redeemer for Stake scripts. data StakeRedeemer = -- | Deposit or withdraw a discrete amount of the staked governance token. - DepositWithdraw Integer + DepositWithdraw (Discrete GTTag) | -- | Destroy a stake, retrieving its LQ, the minimum ADA and any other assets. Destroy deriving stock (Show, GHC.Generic) @@ -116,21 +110,20 @@ data StakeRedeemer PlutusTx.makeIsDataIndexed ''StakeRedeemer [('DepositWithdraw, 0), ('Destroy, 1)] -- | Plutarch-level datum for Stake scripts. -newtype PStakeDatum (gt :: MoneyClass) (s :: S) = PStakeDatum +newtype PStakeDatum (s :: S) = PStakeDatum { getStakeDatum :: - Term s (PDataRecord '["stakedAmount" ':= PDiscrete gt, "owner" ':= PPubKeyHash]) + Term s (PDataRecord '["stakedAmount" ':= PDiscrete GTTag, "owner" ':= PPubKeyHash]) } deriving stock (GHC.Generic) deriving anyclass (Generic) deriving anyclass (PIsDataRepr) deriving (PlutusType, PIsData, PDataFields) - via (PIsDataReprInstances (PStakeDatum gt)) + via (PIsDataReprInstances PStakeDatum) -- | Haskell-level datum for Stake scripts. data StakeDatum = StakeDatum - { -- FIXME: This needs to be gt - stakedAmount :: Integer + { stakedAmount :: Discrete GTTag , owner :: PubKeyHash } deriving stock (Show, GHC.Generic) @@ -154,14 +147,10 @@ PlutusTx.makeIsDataIndexed ''StakeDatum [('StakeDatum, 0)] -- | Policy for Stake state threads. stakePolicy :: - forall (gt :: MoneyClass) ac n scale s. - ( KnownSymbol ac - , KnownSymbol n - , gt ~ '(ac, n, scale) - ) => - Stake gt -> + forall (s :: S). + Stake -> Term s PMintingPolicy -stakePolicy _stake = +stakePolicy stake = plam $ \_redeemer ctx' -> P.do ctx <- pletFields @'["txInfo", "purpose"] ctx' txInfo' <- plet ctx.txInfo @@ -180,7 +169,7 @@ stakePolicy _stake = mintedST #== -1 passert "An unlocked input existed containing an ST" $ - anyInput @(PStakeDatum gt) # pfromData txInfo' + anyInput @PStakeDatum # pfromData txInfo' #$ plam $ \value _ stakeDatum' -> P.do let hasST = psymbolValueOf # ownSymbol # value #== 1 @@ -197,7 +186,7 @@ stakePolicy _stake = mintedST #== 1 passert "A UTXO must exist with the correct output" $ - anyOutput @(PStakeDatum gt) # pfromData txInfo' + anyOutput @PStakeDatum # pfromData txInfo' #$ plam $ \value address stakeDatum' -> P.do let cred = pfield @"credential" # address @@ -220,7 +209,7 @@ stakePolicy _stake = # 1 let expectedValue = paddValue - # (pdiscreteValue # stakeDatum.stakedAmount) + # (pdiscreteValue stake.gtClassRef # stakeDatum.stakedAmount) # stValue let ownerSignsTransaction = ptxSignedBy @@ -234,12 +223,7 @@ stakePolicy _stake = foldr1 (#&&) [ pgeqByClass' (AssetClass ("", "")) # value # expectedValue - , pgeqByClass' - ( AssetClass - ( fromString . symbolVal $ Proxy @ac - , fromString . symbolVal $ Proxy @n - ) - ) + , pgeqByClass' stake.gtClassRef.getAssetClass # value # expectedValue , pgeqByClass @@ -259,12 +243,8 @@ stakePolicy _stake = -- | Validator intended for Stake UTXOs to live in. stakeValidator :: - forall (gt :: MoneyClass) ac n scale s. - ( KnownSymbol ac - , KnownSymbol n - , gt ~ '(ac, n, scale) - ) => - Stake gt -> + forall (s :: S). + Stake -> Term s PValidator stakeValidator stake = plam $ \datum redeemer ctx' -> P.do @@ -273,9 +253,9 @@ stakeValidator stake = txInfo <- pletFields @'["mint", "inputs", "outputs"] txInfo' -- Coercion is safe in that if coercion fails we crash hard. - let stakeRedeemer :: Term _ (PStakeRedeemer gt) + let stakeRedeemer :: Term _ PStakeRedeemer stakeRedeemer = pfromData $ punsafeCoerce redeemer - stakeDatum' :: Term _ (PStakeDatum gt) + stakeDatum' :: Term _ PStakeDatum stakeDatum' = pfromData $ punsafeCoerce datum stakeDatum <- pletFields @'["owner", "stakedAmount"] stakeDatum' @@ -310,7 +290,7 @@ stakeValidator stake = "Owner signs this transaction" ownerSignsTransaction passert "A UTXO must exist with the correct output" $ - anyOutput @(PStakeDatum gt) # txInfo' + anyOutput @PStakeDatum # txInfo' #$ plam $ \value address newStakeDatum' -> P.do newStakeDatum <- pletFields @'["owner", "stakedAmount"] newStakeDatum' @@ -325,7 +305,10 @@ stakeValidator stake = -- do we need to check this, really? pgeqDiscrete # (pfromData newStakeDatum.stakedAmount) # pzeroDiscrete ] - let expectedValue = paddValue # continuingValue # (pdiscreteValue # delta) + let expectedValue = paddValue # continuingValue # (pdiscreteValue stake.gtClassRef # delta) + + ptrace (pshow $ passetClassValueOf' stake.gtClassRef.getAssetClass # value) + ptrace (pshow $ passetClassValueOf' stake.gtClassRef.getAssetClass # expectedValue) -- TODO: Same as above. This is quite inefficient now, as it does two lookups -- instead of a more efficient single pass, @@ -334,12 +317,7 @@ stakeValidator stake = foldr1 (#&&) [ pgeqByClass' (AssetClass ("", "")) # value # expectedValue - , pgeqByClass' - ( AssetClass - ( fromString . symbolVal $ Proxy @ac - , fromString . symbolVal $ Proxy @n - ) - ) + , pgeqByClass' stake.gtClassRef.getAssetClass # value # expectedValue , pgeqBySymbol @@ -360,7 +338,7 @@ stakeValidator stake = -------------------------------------------------------------------------------- -- | Check whether a Stake is locked. If it is locked, various actions are unavailable. -stakeLocked :: forall (gt :: MoneyClass) s. Term s (PStakeDatum gt :--> PBool) +stakeLocked :: forall (s :: S). Term s (PStakeDatum :--> PBool) stakeLocked = phoistAcyclic $ plam $ \_stakeDatum -> -- TODO: when we extend this to support proposals, this will need to do something diff --git a/agora/Agora/Utils.hs b/agora/Agora/Utils.hs index 9c5224a..2f875b0 100644 --- a/agora/Agora/Utils.hs +++ b/agora/Agora/Utils.hs @@ -183,21 +183,21 @@ passetClassValueOf' :: AssetClass -> Term s (PValue :--> PInteger) passetClassValueOf' (AssetClass (sym, token)) = passetClassValueOf # pconstant sym # pconstant token --- | Return '>=' on two values comparing by only a particular AssetClass +-- | Return '>=' on two values comparing by only a particular AssetClass. pgeqByClass :: Term s (PCurrencySymbol :--> PTokenName :--> PValue :--> PValue :--> PBool) pgeqByClass = phoistAcyclic $ plam $ \cs tn a b -> passetClassValueOf # cs # tn # b #<= passetClassValueOf # cs # tn # a --- | Return '>=' on two values comparing by only a particular CurrencySymbol +-- | Return '>=' on two values comparing by only a particular CurrencySymbol. pgeqBySymbol :: Term s (PCurrencySymbol :--> PValue :--> PValue :--> PBool) pgeqBySymbol = phoistAcyclic $ plam $ \cs a b -> psymbolValueOf # cs # b #<= psymbolValueOf # cs # a --- | Return '>=' on two values comparing by only a particular Haskell-level AssetClass +-- | Return '>=' on two values comparing by only a particular Haskell-level AssetClass. pgeqByClass' :: AssetClass -> Term s (PValue :--> PValue :--> PBool) pgeqByClass' ac = phoistAcyclic $ @@ -233,7 +233,7 @@ pmapUnionWith = phoistAcyclic $ # ys pcon (PMap $ pconcat # ls # rs) --- | Add two 'PValue's together +-- | Add two 'PValue's together. paddValue :: forall s. Term s (PValue :--> PValue :--> PValue) paddValue = phoistAcyclic $ plam $ \a' b' -> P.do diff --git a/agora/Agora/Voting.hs b/agora/Agora/Voting.hs deleted file mode 100644 index 5436960..0000000 --- a/agora/Agora/Voting.hs +++ /dev/null @@ -1,11 +0,0 @@ -{- | -Module : Agora.Voting -Maintainer : emi@haskell.fyi -Description: Types for votes and vote counting --} -module Agora.Voting ( - Vote (..), -) where - --- | Type representing direction of vote. -data Vote = InFavorOf | OpposedTo diff --git a/agora/PPrelude.hs b/agora/PPrelude.hs index 8fba4be..3232cf9 100644 --- a/agora/PPrelude.hs +++ b/agora/PPrelude.hs @@ -11,7 +11,8 @@ module PPrelude ( module Plutarch, ) where --- These are not exported by Plutarch.Prelude, for some reason. Maybe we can 'fix' this upstream? -import Plutarch (ClosedTerm, compile) +-- NOTE: These are not exported by Plutarch.Prelude, for some reason. +-- Maybe we can 'fix' this upstream? +import Plutarch (ClosedTerm, POpaque, compile) import Plutarch.Prelude import Prelude diff --git a/flake.lock b/flake.lock deleted file mode 100644 index 3a16dd7..0000000 --- a/flake.lock +++ /dev/null @@ -1,1994 +0,0 @@ -{ - "nodes": { - "HTTP": { - "flake": false, - "locked": { - "lastModified": 1451647621, - "narHash": "sha256-oHIyw3x0iKBexEo49YeUDV1k74ZtyYKGR2gNJXXRxts=", - "owner": "phadej", - "repo": "HTTP", - "rev": "9bc0996d412fef1787449d841277ef663ad9a915", - "type": "github" - }, - "original": { - "owner": "phadej", - "repo": "HTTP", - "type": "github" - } - }, - "HTTP_2": { - "flake": false, - "locked": { - "lastModified": 1451647621, - "narHash": "sha256-oHIyw3x0iKBexEo49YeUDV1k74ZtyYKGR2gNJXXRxts=", - "owner": "phadej", - "repo": "HTTP", - "rev": "9bc0996d412fef1787449d841277ef663ad9a915", - "type": "github" - }, - "original": { - "owner": "phadej", - "repo": "HTTP", - "type": "github" - } - }, - "HTTP_3": { - "flake": false, - "locked": { - "lastModified": 1451647621, - "narHash": "sha256-oHIyw3x0iKBexEo49YeUDV1k74ZtyYKGR2gNJXXRxts=", - "owner": "phadej", - "repo": "HTTP", - "rev": "9bc0996d412fef1787449d841277ef663ad9a915", - "type": "github" - }, - "original": { - "owner": "phadej", - "repo": "HTTP", - "type": "github" - } - }, - "Shrinker": { - "flake": false, - "locked": { - "lastModified": 1642430208, - "narHash": "sha256-tfWyB7zCLzncwRpyl7eUOzuOBbg9KLu6sxSxRaFlOug=", - "owner": "Plutonomicon", - "repo": "Shrinker", - "rev": "0e60707996b876c7bd23a348f54545217ce2e556", - "type": "github" - }, - "original": { - "owner": "Plutonomicon", - "repo": "Shrinker", - "type": "github" - } - }, - "apropos": { - "inputs": { - "flake-compat": "flake-compat", - "flake-compat-ci": "flake-compat-ci", - "haskell-nix": "haskell-nix", - "nixpkgs": [ - "apropos", - "haskell-nix", - "nixpkgs-unstable" - ] - }, - "locked": { - "lastModified": 1648746740, - "narHash": "sha256-C2gQrd5hFvQ+BsjAJs6V0iP9PRzd9dZMKtpk7kOjhwc=", - "owner": "mlabs-haskell", - "repo": "apropos", - "rev": "3734bb3baa297ed990725a5ef14efcbb6a1c1c23", - "type": "github" - }, - "original": { - "owner": "mlabs-haskell", - "repo": "apropos", - "rev": "3734bb3baa297ed990725a5ef14efcbb6a1c1c23", - "type": "github" - } - }, - "apropos-tx": { - "inputs": { - "flake-compat": "flake-compat_2", - "flake-compat-ci": "flake-compat-ci_2", - "haskell-nix": "haskell-nix_2", - "nixpkgs": [ - "plutarch", - "haskell-nix", - "nixpkgs-unstable" - ], - "plutus": "plutus" - }, - "locked": { - "lastModified": 1648805998, - "narHash": "sha256-TWEiUifHkhgCHqe70aNn9j6LdFFWv2nMbSWV8hR59oE=", - "owner": "jhodgdev", - "repo": "apropos-tx", - "rev": "4eca3fac23c339caee04ea6176e641a4b3857a25", - "type": "github" - }, - "original": { - "owner": "jhodgdev", - "repo": "apropos-tx", - "rev": "4eca3fac23c339caee04ea6176e641a4b3857a25", - "type": "github" - } - }, - "autodocodec": { - "flake": false, - "locked": { - "lastModified": 1644358110, - "narHash": "sha256-X1TNZlmO2qDFk3OL4Z1v/gzvd3ouoACAiMweutsYek4=", - "owner": "srid", - "repo": "autodocodec", - "rev": "42b42a7407f33c6c74fa4e8c84906aebfed28daf", - "type": "github" - }, - "original": { - "owner": "srid", - "ref": "ghc921", - "repo": "autodocodec", - "type": "github" - } - }, - "cabal-32": { - "flake": false, - "locked": { - "lastModified": 1603716527, - "narHash": "sha256-X0TFfdD4KZpwl0Zr6x+PLxUt/VyKQfX7ylXHdmZIL+w=", - "owner": "haskell", - "repo": "cabal", - "rev": "48bf10787e27364730dd37a42b603cee8d6af7ee", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "3.2", - "repo": "cabal", - "type": "github" - } - }, - "cabal-32_2": { - "flake": false, - "locked": { - "lastModified": 1603716527, - "narHash": "sha256-X0TFfdD4KZpwl0Zr6x+PLxUt/VyKQfX7ylXHdmZIL+w=", - "owner": "haskell", - "repo": "cabal", - "rev": "48bf10787e27364730dd37a42b603cee8d6af7ee", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "3.2", - "repo": "cabal", - "type": "github" - } - }, - "cabal-32_3": { - "flake": false, - "locked": { - "lastModified": 1603716527, - "narHash": "sha256-sDbrmur9Zfp4mPKohCD8IDZfXJ0Tjxpmr2R+kg5PpSY=", - "owner": "haskell", - "repo": "cabal", - "rev": "94aaa8e4720081f9c75497e2735b90f6a819b08e", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "3.2", - "repo": "cabal", - "type": "github" - } - }, - "cabal-34": { - "flake": false, - "locked": { - "lastModified": 1640353650, - "narHash": "sha256-N1t6M3/wqj90AEdRkeC8i923gQYUpzSr8b40qVOZ1Rk=", - "owner": "haskell", - "repo": "cabal", - "rev": "942639c18c0cd8ec53e0a6f8d120091af35312cd", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "3.4", - "repo": "cabal", - "type": "github" - } - }, - "cabal-34_2": { - "flake": false, - "locked": { - "lastModified": 1640353650, - "narHash": "sha256-N1t6M3/wqj90AEdRkeC8i923gQYUpzSr8b40qVOZ1Rk=", - "owner": "haskell", - "repo": "cabal", - "rev": "942639c18c0cd8ec53e0a6f8d120091af35312cd", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "3.4", - "repo": "cabal", - "type": "github" - } - }, - "cabal-34_3": { - "flake": false, - "locked": { - "lastModified": 1622475795, - "narHash": "sha256-chwTL304Cav+7p38d9mcb+egABWmxo2Aq+xgVBgEb/U=", - "owner": "haskell", - "repo": "cabal", - "rev": "b086c1995cdd616fc8d91f46a21e905cc50a1049", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "3.4", - "repo": "cabal", - "type": "github" - } - }, - "cabal-36": { - "flake": false, - "locked": { - "lastModified": 1641652457, - "narHash": "sha256-BlFPKP4C4HRUJeAbdembX1Rms1LD380q9s0qVDeoAak=", - "owner": "haskell", - "repo": "cabal", - "rev": "f27667f8ec360c475027dcaee0138c937477b070", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "3.6", - "repo": "cabal", - "type": "github" - } - }, - "cabal-36_2": { - "flake": false, - "locked": { - "lastModified": 1641652457, - "narHash": "sha256-BlFPKP4C4HRUJeAbdembX1Rms1LD380q9s0qVDeoAak=", - "owner": "haskell", - "repo": "cabal", - "rev": "f27667f8ec360c475027dcaee0138c937477b070", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "3.6", - "repo": "cabal", - "type": "github" - } - }, - "cabal-36_3": { - "flake": false, - "locked": { - "lastModified": 1640163203, - "narHash": "sha256-TwDWP2CffT0j40W6zr0J1Qbu+oh3nsF1lUx9446qxZM=", - "owner": "haskell", - "repo": "cabal", - "rev": "ecf418050c1821f25e2e218f1be94c31e0465df1", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "3.6", - "repo": "cabal", - "type": "github" - } - }, - "cardano-base": { - "flake": false, - "locked": { - "lastModified": 1638456794, - "narHash": "sha256-0KAO6dWqupJzRyjWjAFLZrt0hA6pozeKsDv1Fnysib8=", - "owner": "input-output-hk", - "repo": "cardano-base", - "rev": "4fae3f0149fd8925be94707d3ae0e36c0d67bd58", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "cardano-base", - "type": "github" - } - }, - "cardano-crypto": { - "flake": false, - "locked": { - "lastModified": 1621376239, - "narHash": "sha256-oxIOVlgm07FAEmgGRF1C2me9TXqVxQulEOcJ22zpTRs=", - "owner": "input-output-hk", - "repo": "cardano-crypto", - "rev": "07397f0e50da97eaa0575d93bee7ac4b2b2576ec", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "cardano-crypto", - "rev": "07397f0e50da97eaa0575d93bee7ac4b2b2576ec", - "type": "github" - } - }, - "cardano-prelude": { - "flake": false, - "locked": { - "lastModified": 1641566029, - "narHash": "sha256-CylaHhO4zbZ1dEAv8yWp1swP1xys/s2Sbxg3a2pdnCI=", - "owner": "locallycompact", - "repo": "cardano-prelude", - "rev": "93f95047bb36a055bdd56fb0cafd887c072cdce2", - "type": "github" - }, - "original": { - "owner": "locallycompact", - "repo": "cardano-prelude", - "rev": "93f95047bb36a055bdd56fb0cafd887c072cdce2", - "type": "github" - } - }, - "cardano-repo-tool": { - "flake": false, - "locked": { - "lastModified": 1624584417, - "narHash": "sha256-YSepT97PagR/1jTYV/Yer8a2GjFe9+tTwaTCHxuK50M=", - "owner": "input-output-hk", - "repo": "cardano-repo-tool", - "rev": "30e826ed8f00e3e154453b122a6f3d779b2f73ec", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "cardano-repo-tool", - "type": "github" - } - }, - "cardano-repo-tool_2": { - "flake": false, - "locked": { - "lastModified": 1624584417, - "narHash": "sha256-YSepT97PagR/1jTYV/Yer8a2GjFe9+tTwaTCHxuK50M=", - "owner": "input-output-hk", - "repo": "cardano-repo-tool", - "rev": "30e826ed8f00e3e154453b122a6f3d779b2f73ec", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "cardano-repo-tool", - "type": "github" - } - }, - "cardano-shell": { - "flake": false, - "locked": { - "lastModified": 1608537748, - "narHash": "sha256-PulY1GfiMgKVnBci3ex4ptk2UNYMXqGjJOxcPy2KYT4=", - "owner": "input-output-hk", - "repo": "cardano-shell", - "rev": "9392c75087cb9a3d453998f4230930dea3a95725", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "cardano-shell", - "type": "github" - } - }, - "cardano-shell_2": { - "flake": false, - "locked": { - "lastModified": 1608537748, - "narHash": "sha256-PulY1GfiMgKVnBci3ex4ptk2UNYMXqGjJOxcPy2KYT4=", - "owner": "input-output-hk", - "repo": "cardano-shell", - "rev": "9392c75087cb9a3d453998f4230930dea3a95725", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "cardano-shell", - "type": "github" - } - }, - "cardano-shell_3": { - "flake": false, - "locked": { - "lastModified": 1608537748, - "narHash": "sha256-PulY1GfiMgKVnBci3ex4ptk2UNYMXqGjJOxcPy2KYT4=", - "owner": "input-output-hk", - "repo": "cardano-shell", - "rev": "9392c75087cb9a3d453998f4230930dea3a95725", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "cardano-shell", - "type": "github" - } - }, - "cryptonite": { - "flake": false, - "locked": { - "lastModified": 1639749289, - "narHash": "sha256-/KS2S0f9r4c/q+IUGwkFOY9jbZkyK3dl0xMpDbULeqc=", - "owner": "haskell-crypto", - "repo": "cryptonite", - "rev": "cec291d988f0f17828384f3358214ab9bf724a13", - "type": "github" - }, - "original": { - "owner": "haskell-crypto", - "repo": "cryptonite", - "rev": "cec291d988f0f17828384f3358214ab9bf724a13", - "type": "github" - } - }, - "flake-compat": { - "flake": false, - "locked": { - "lastModified": 1641205782, - "narHash": "sha256-4jY7RCWUoZ9cKD8co0/4tFARpWB+57+r1bLLvXNJliY=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "b7547d3eed6f32d06102ead8991ec52ab0a4f1a7", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-compat-ci": { - "locked": { - "lastModified": 1641672839, - "narHash": "sha256-Bdwv+DKeEMlRNPDpZxSz0sSrqQBvdKO5fZ8LmvrgCOU=", - "owner": "hercules-ci", - "repo": "flake-compat-ci", - "rev": "e832114bc18376c0f3fa13c19bf5ff253cc6570a", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "repo": "flake-compat-ci", - "type": "github" - } - }, - "flake-compat-ci_2": { - "locked": { - "lastModified": 1641672839, - "narHash": "sha256-Bdwv+DKeEMlRNPDpZxSz0sSrqQBvdKO5fZ8LmvrgCOU=", - "owner": "hercules-ci", - "repo": "flake-compat-ci", - "rev": "e832114bc18376c0f3fa13c19bf5ff253cc6570a", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "repo": "flake-compat-ci", - "type": "github" - } - }, - "flake-compat-ci_3": { - "locked": { - "lastModified": 1641672839, - "narHash": "sha256-Bdwv+DKeEMlRNPDpZxSz0sSrqQBvdKO5fZ8LmvrgCOU=", - "owner": "hercules-ci", - "repo": "flake-compat-ci", - "rev": "e832114bc18376c0f3fa13c19bf5ff253cc6570a", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "repo": "flake-compat-ci", - "type": "github" - } - }, - "flake-compat_2": { - "flake": false, - "locked": { - "lastModified": 1641205782, - "narHash": "sha256-4jY7RCWUoZ9cKD8co0/4tFARpWB+57+r1bLLvXNJliY=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "b7547d3eed6f32d06102ead8991ec52ab0a4f1a7", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-compat_3": { - "flake": false, - "locked": { - "lastModified": 1641205782, - "narHash": "sha256-4jY7RCWUoZ9cKD8co0/4tFARpWB+57+r1bLLvXNJliY=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "b7547d3eed6f32d06102ead8991ec52ab0a4f1a7", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-compat_4": { - "flake": false, - "locked": { - "lastModified": 1606424373, - "narHash": "sha256-oq8d4//CJOrVj+EcOaSXvMebvuTkmBJuT5tzlfewUnQ=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "99f1c2157fba4bfe6211a321fd0ee43199025dbf", - "type": "github" - }, - "original": { - "owner": "edolstra", - "ref": "master", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-compat_5": { - "flake": false, - "locked": { - "lastModified": 1606424373, - "narHash": "sha256-oq8d4//CJOrVj+EcOaSXvMebvuTkmBJuT5tzlfewUnQ=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "99f1c2157fba4bfe6211a321fd0ee43199025dbf", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-utils": { - "locked": { - "lastModified": 1644229661, - "narHash": "sha256-1YdnJAsNy69bpcjuoKdOYQX0YxZBiCYZo4Twxerqv7k=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3cecb5b042f7f209c56ffd8371b2711a290ec797", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "flake-utils_2": { - "locked": { - "lastModified": 1644229661, - "narHash": "sha256-1YdnJAsNy69bpcjuoKdOYQX0YxZBiCYZo4Twxerqv7k=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3cecb5b042f7f209c56ffd8371b2711a290ec797", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "flake-utils_3": { - "locked": { - "lastModified": 1623875721, - "narHash": "sha256-A8BU7bjS5GirpAUv4QA+QnJ4CceLHkcXdRp4xITDB0s=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "f7e004a55b120c02ecb6219596820fcd32ca8772", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "flat": { - "flake": false, - "locked": { - "lastModified": 1641898475, - "narHash": "sha256-D7jJ4t0T1ZvXbO61r3HQj77hZ5hWF/P1L8X9+MnfD6c=", - "owner": "Quid2", - "repo": "flat", - "rev": "41a040c413351e021982bb78bd00f750628f8060", - "type": "github" - }, - "original": { - "owner": "Quid2", - "repo": "flat", - "rev": "41a040c413351e021982bb78bd00f750628f8060", - "type": "github" - } - }, - "foundation": { - "flake": false, - "locked": { - "lastModified": 1635711016, - "narHash": "sha256-5TRuljpwt50DLjyFjiFj6quFncu8RT0d8/0jlzsenuc=", - "owner": "haskell-foundation", - "repo": "foundation", - "rev": "0bb195e1fea06d144dafc5af9a0ff79af0a5f4a0", - "type": "github" - }, - "original": { - "owner": "haskell-foundation", - "repo": "foundation", - "rev": "0bb195e1fea06d144dafc5af9a0ff79af0a5f4a0", - "type": "github" - } - }, - "ghc-8.6.5-iohk": { - "flake": false, - "locked": { - "lastModified": 1600920045, - "narHash": "sha256-DO6kxJz248djebZLpSzTGD6s8WRpNI9BTwUeOf5RwY8=", - "owner": "input-output-hk", - "repo": "ghc", - "rev": "95713a6ecce4551240da7c96b6176f980af75cae", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "ref": "release/8.6.5-iohk", - "repo": "ghc", - "type": "github" - } - }, - "ghc-8.6.5-iohk_2": { - "flake": false, - "locked": { - "lastModified": 1600920045, - "narHash": "sha256-DO6kxJz248djebZLpSzTGD6s8WRpNI9BTwUeOf5RwY8=", - "owner": "input-output-hk", - "repo": "ghc", - "rev": "95713a6ecce4551240da7c96b6176f980af75cae", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "ref": "release/8.6.5-iohk", - "repo": "ghc", - "type": "github" - } - }, - "ghc-8.6.5-iohk_3": { - "flake": false, - "locked": { - "lastModified": 1600920045, - "narHash": "sha256-DO6kxJz248djebZLpSzTGD6s8WRpNI9BTwUeOf5RwY8=", - "owner": "input-output-hk", - "repo": "ghc", - "rev": "95713a6ecce4551240da7c96b6176f980af75cae", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "ref": "release/8.6.5-iohk", - "repo": "ghc", - "type": "github" - } - }, - "gitignore-nix": { - "flake": false, - "locked": { - "lastModified": 1611672876, - "narHash": "sha256-qHu3uZ/o9jBHiA3MEKHJ06k7w4heOhA+4HCSIvflRxo=", - "owner": "hercules-ci", - "repo": "gitignore.nix", - "rev": "211907489e9f198594c0eb0ca9256a1949c9d412", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "repo": "gitignore.nix", - "type": "github" - } - }, - "gitignore-nix_2": { - "flake": false, - "locked": { - "lastModified": 1611672876, - "narHash": "sha256-qHu3uZ/o9jBHiA3MEKHJ06k7w4heOhA+4HCSIvflRxo=", - "owner": "hercules-ci", - "repo": "gitignore.nix", - "rev": "211907489e9f198594c0eb0ca9256a1949c9d412", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "repo": "gitignore.nix", - "type": "github" - } - }, - "hackage": { - "flake": false, - "locked": { - "lastModified": 1646270198, - "narHash": "sha256-SakG546Zr9RuNPs5mhtT7CYPpvEDMGrWisWK/VpCvr0=", - "owner": "input-output-hk", - "repo": "hackage.nix", - "rev": "4cf90b36955597d0151940eabfb1b61a8ec42256", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "hackage.nix", - "type": "github" - } - }, - "hackage-nix": { - "flake": false, - "locked": { - "lastModified": 1644369434, - "narHash": "sha256-WqU6f1OhSM0UHXFW8Mhhvhz0tcij+NQVtmb6sW4RiFw=", - "owner": "input-output-hk", - "repo": "hackage.nix", - "rev": "644a0d702abf84cdec62f4e620ff1034000e6146", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "hackage.nix", - "type": "github" - } - }, - "hackage-nix_2": { - "flake": false, - "locked": { - "lastModified": 1637291070, - "narHash": "sha256-hTX2Xo36i9MR6PNwA/89C8daKjxmx5ZS5lwR2Cbp8Yo=", - "owner": "input-output-hk", - "repo": "hackage.nix", - "rev": "6ea4ad5f4a5e2303cd64974329ba90ccc410a012", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "hackage.nix", - "type": "github" - } - }, - "hackage_2": { - "flake": false, - "locked": { - "lastModified": 1646270198, - "narHash": "sha256-SakG546Zr9RuNPs5mhtT7CYPpvEDMGrWisWK/VpCvr0=", - "owner": "input-output-hk", - "repo": "hackage.nix", - "rev": "4cf90b36955597d0151940eabfb1b61a8ec42256", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "hackage.nix", - "type": "github" - } - }, - "hackage_3": { - "flake": false, - "locked": { - "lastModified": 1642554756, - "narHash": "sha256-1+SN+z80HgKYshlCf8dRxwRojQzuwwsQ5uq14N/JP1Y=", - "owner": "input-output-hk", - "repo": "hackage.nix", - "rev": "f9d5e67ca90926b244c0ad68815371d37582a149", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "hackage.nix", - "type": "github" - } - }, - "haskell-language-server": { - "flake": false, - "locked": { - "lastModified": 1643835246, - "narHash": "sha256-5LQHcQmi3mUGRgJu+X/m3jeM3kdkYjLD+KwgnxBlbeU=", - "owner": "haskell", - "repo": "haskell-language-server", - "rev": "024ddc8b3904f8b8e8fe67ba6b9ebd8a4bd7ce76", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "1.6.1.1", - "repo": "haskell-language-server", - "type": "github" - } - }, - "haskell-language-server_2": { - "flake": false, - "locked": { - "lastModified": 1642772345, - "narHash": "sha256-fjdNOcd0S35OAvMZu81/im32B7hSIimjs08VKQA58Mw=", - "owner": "haskell", - "repo": "haskell-language-server", - "rev": "f0bbc390b995953885506b755f4e4b5c6af618fb", - "type": "github" - }, - "original": { - "owner": "haskell", - "repo": "haskell-language-server", - "type": "github" - } - }, - "haskell-language-server_3": { - "flake": false, - "locked": { - "lastModified": 1643835246, - "narHash": "sha256-5LQHcQmi3mUGRgJu+X/m3jeM3kdkYjLD+KwgnxBlbeU=", - "owner": "haskell", - "repo": "haskell-language-server", - "rev": "024ddc8b3904f8b8e8fe67ba6b9ebd8a4bd7ce76", - "type": "github" - }, - "original": { - "owner": "haskell", - "ref": "1.6.1.1", - "repo": "haskell-language-server", - "type": "github" - } - }, - "haskell-nix": { - "inputs": { - "HTTP": "HTTP", - "cabal-32": "cabal-32", - "cabal-34": "cabal-34", - "cabal-36": "cabal-36", - "cardano-shell": "cardano-shell", - "flake-utils": "flake-utils", - "ghc-8.6.5-iohk": "ghc-8.6.5-iohk", - "hackage": "hackage", - "hpc-coveralls": "hpc-coveralls", - "nix-tools": "nix-tools", - "nixpkgs": [ - "apropos", - "haskell-nix", - "nixpkgs-2105" - ], - "nixpkgs-2003": "nixpkgs-2003", - "nixpkgs-2105": "nixpkgs-2105", - "nixpkgs-2111": "nixpkgs-2111", - "nixpkgs-unstable": "nixpkgs-unstable", - "old-ghc-nix": "old-ghc-nix", - "stackage": "stackage" - }, - "locked": { - "lastModified": 1646278384, - "narHash": "sha256-Gv1Ws3vAojjvjATcsvwAOTuOhzpxwt6tBci7EBaXxU4=", - "owner": "input-output-hk", - "repo": "haskell.nix", - "rev": "7e06e14ae1b894445254fe41288bfa7dd4ccbc6f", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "haskell.nix", - "type": "github" - } - }, - "haskell-nix_2": { - "inputs": { - "HTTP": "HTTP_2", - "cabal-32": "cabal-32_2", - "cabal-34": "cabal-34_2", - "cabal-36": "cabal-36_2", - "cardano-shell": "cardano-shell_2", - "flake-utils": "flake-utils_2", - "ghc-8.6.5-iohk": "ghc-8.6.5-iohk_2", - "hackage": "hackage_2", - "hpc-coveralls": "hpc-coveralls_2", - "nix-tools": "nix-tools_2", - "nixpkgs": [ - "apropos-tx", - "haskell-nix", - "nixpkgs-2105" - ], - "nixpkgs-2003": "nixpkgs-2003_2", - "nixpkgs-2105": "nixpkgs-2105_2", - "nixpkgs-2111": "nixpkgs-2111_2", - "nixpkgs-unstable": "nixpkgs-unstable_2", - "old-ghc-nix": "old-ghc-nix_2", - "stackage": "stackage_2" - }, - "locked": { - "lastModified": 1646278384, - "narHash": "sha256-Gv1Ws3vAojjvjATcsvwAOTuOhzpxwt6tBci7EBaXxU4=", - "owner": "input-output-hk", - "repo": "haskell.nix", - "rev": "7e06e14ae1b894445254fe41288bfa7dd4ccbc6f", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "haskell.nix", - "type": "github" - } - }, - "haskell-nix_3": { - "flake": false, - "locked": { - "lastModified": 1646278384, - "narHash": "sha256-Gv1Ws3vAojjvjATcsvwAOTuOhzpxwt6tBci7EBaXxU4=", - "owner": "input-output-hk", - "repo": "haskell.nix", - "rev": "7e06e14ae1b894445254fe41288bfa7dd4ccbc6f", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "haskell.nix", - "type": "github" - } - }, - "haskell-nix_4": { - "inputs": { - "HTTP": "HTTP_3", - "cabal-32": "cabal-32_3", - "cabal-34": "cabal-34_3", - "cabal-36": "cabal-36_3", - "cardano-shell": "cardano-shell_3", - "flake-utils": "flake-utils_3", - "ghc-8.6.5-iohk": "ghc-8.6.5-iohk_3", - "hackage": "hackage_3", - "hpc-coveralls": "hpc-coveralls_3", - "nix-tools": "nix-tools_3", - "nixpkgs": [ - "plutarch", - "haskell-nix", - "nixpkgs-2111" - ], - "nixpkgs-2003": "nixpkgs-2003_3", - "nixpkgs-2105": "nixpkgs-2105_3", - "nixpkgs-2111": "nixpkgs-2111_4", - "nixpkgs-unstable": "nixpkgs-unstable_3", - "old-ghc-nix": "old-ghc-nix_3", - "stackage": "stackage_3" - }, - "locked": { - "lastModified": 1642811877, - "narHash": "sha256-7YbbFF4ISWMcs5hHDfH7GkCSccvwEwhvKZ5D74Cuajo=", - "owner": "L-as", - "repo": "haskell.nix", - "rev": "ac825b91c202947ec59b1a477003564cc018fcec", - "type": "github" - }, - "original": { - "owner": "L-as", - "ref": "master", - "repo": "haskell.nix", - "type": "github" - } - }, - "haskell-nix_5": { - "flake": false, - "locked": { - "lastModified": 1629380841, - "narHash": "sha256-gWOWCfX7IgVSvMMYN6rBGK6EA0pk6pmYguXzMvGte+Q=", - "owner": "input-output-hk", - "repo": "haskell.nix", - "rev": "7215f083b37741446aa325b20c8ba9f9f76015eb", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "haskell.nix", - "type": "github" - } - }, - "hercules-ci-agent": { - "inputs": { - "flake-compat": "flake-compat_5", - "nix-darwin": "nix-darwin", - "nixos-20_09": "nixos-20_09", - "nixos-unstable": "nixos-unstable", - "pre-commit-hooks-nix": "pre-commit-hooks-nix_2" - }, - "locked": { - "lastModified": 1642766877, - "narHash": "sha256-EXvI+1cKZHWfAaRV1PrSrQe0knc4rg5vMF4qz6/5bkI=", - "owner": "hercules-ci", - "repo": "hercules-ci-agent", - "rev": "0aa916f487be7da03bc2a6dec2ac7149b05499c5", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "ref": "master", - "repo": "hercules-ci-agent", - "type": "github" - } - }, - "hercules-ci-effects": { - "inputs": { - "flake-compat": "flake-compat_4", - "hercules-ci-agent": "hercules-ci-agent", - "nixpkgs": "nixpkgs_3", - "nixpkgs-nixops": "nixpkgs-nixops" - }, - "locked": { - "lastModified": 1641914281, - "narHash": "sha256-3qJ6tDPkrsFqm4E74JROZlQbnKKLNTHV7QOD1LdcVqs=", - "owner": "hercules-ci", - "repo": "hercules-ci-effects", - "rev": "2e165352d92782e7ae149f4f1a9b3174f718a3af", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "repo": "hercules-ci-effects", - "type": "github" - } - }, - "hpc-coveralls": { - "flake": false, - "locked": { - "lastModified": 1607498076, - "narHash": "sha256-8uqsEtivphgZWYeUo5RDUhp6bO9j2vaaProQxHBltQk=", - "owner": "sevanspowell", - "repo": "hpc-coveralls", - "rev": "14df0f7d229f4cd2e79f8eabb1a740097fdfa430", - "type": "github" - }, - "original": { - "owner": "sevanspowell", - "repo": "hpc-coveralls", - "type": "github" - } - }, - "hpc-coveralls_2": { - "flake": false, - "locked": { - "lastModified": 1607498076, - "narHash": "sha256-8uqsEtivphgZWYeUo5RDUhp6bO9j2vaaProQxHBltQk=", - "owner": "sevanspowell", - "repo": "hpc-coveralls", - "rev": "14df0f7d229f4cd2e79f8eabb1a740097fdfa430", - "type": "github" - }, - "original": { - "owner": "sevanspowell", - "repo": "hpc-coveralls", - "type": "github" - } - }, - "hpc-coveralls_3": { - "flake": false, - "locked": { - "lastModified": 1607498076, - "narHash": "sha256-8uqsEtivphgZWYeUo5RDUhp6bO9j2vaaProQxHBltQk=", - "owner": "sevanspowell", - "repo": "hpc-coveralls", - "rev": "14df0f7d229f4cd2e79f8eabb1a740097fdfa430", - "type": "github" - }, - "original": { - "owner": "sevanspowell", - "repo": "hpc-coveralls", - "type": "github" - } - }, - "hs-memory": { - "flake": false, - "locked": { - "lastModified": 1636757734, - "narHash": "sha256-DIlt0NpFUx8IUeTcgZNBJWWfyNaKv5ZKYw1K9aLvxBs=", - "owner": "vincenthz", - "repo": "hs-memory", - "rev": "3cf661a8a9a8ac028df77daa88e8d65c55a3347a", - "type": "github" - }, - "original": { - "owner": "vincenthz", - "repo": "hs-memory", - "rev": "3cf661a8a9a8ac028df77daa88e8d65c55a3347a", - "type": "github" - } - }, - "iohk-nix": { - "flake": false, - "locked": { - "lastModified": 1626953580, - "narHash": "sha256-iEI9aTOaZMGsjWzcrctrC0usmiagwKT2v1LSDe9/tMU=", - "owner": "input-output-hk", - "repo": "iohk-nix", - "rev": "cbd497f5844249ef8fe617166337d59f2a6ebe90", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "iohk-nix", - "type": "github" - } - }, - "iohk-nix_2": { - "flake": false, - "locked": { - "lastModified": 1648032999, - "narHash": "sha256-3uCz+gJppvM7z6CUCkBbFSu60WgIE+e3oXwXiAiGWSY=", - "owner": "input-output-hk", - "repo": "iohk-nix", - "rev": "5e667b374153327c7bdfdbfab8ef19b1f27d4aac", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "iohk-nix", - "type": "github" - } - }, - "iohk-nix_3": { - "flake": false, - "locked": { - "lastModified": 1626953580, - "narHash": "sha256-iEI9aTOaZMGsjWzcrctrC0usmiagwKT2v1LSDe9/tMU=", - "owner": "input-output-hk", - "repo": "iohk-nix", - "rev": "cbd497f5844249ef8fe617166337d59f2a6ebe90", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "iohk-nix", - "type": "github" - } - }, - "nix-darwin": { - "inputs": { - "nixpkgs": "nixpkgs_2" - }, - "locked": { - "lastModified": 1622060422, - "narHash": "sha256-hPVlvrAyf6zL7tTx0lpK+tMxEfZeMiIZ/A2xaJ41WOY=", - "owner": "LnL7", - "repo": "nix-darwin", - "rev": "007d700e644ac588ad6668e6439950a5b6e2ff64", - "type": "github" - }, - "original": { - "owner": "LnL7", - "repo": "nix-darwin", - "type": "github" - } - }, - "nix-tools": { - "flake": false, - "locked": { - "lastModified": 1644395812, - "narHash": "sha256-BVFk/BEsTLq5MMZvdy3ZYHKfaS3dHrsKh4+tb5t5b58=", - "owner": "input-output-hk", - "repo": "nix-tools", - "rev": "d847c63b99bbec78bf83be2a61dc9f09b8a9ccc1", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "nix-tools", - "type": "github" - } - }, - "nix-tools_2": { - "flake": false, - "locked": { - "lastModified": 1644395812, - "narHash": "sha256-BVFk/BEsTLq5MMZvdy3ZYHKfaS3dHrsKh4+tb5t5b58=", - "owner": "input-output-hk", - "repo": "nix-tools", - "rev": "d847c63b99bbec78bf83be2a61dc9f09b8a9ccc1", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "nix-tools", - "type": "github" - } - }, - "nix-tools_3": { - "flake": false, - "locked": { - "lastModified": 1636018067, - "narHash": "sha256-ng306fkuwr6V/malWtt3979iAC4yMVDDH2ViwYB6sQE=", - "owner": "input-output-hk", - "repo": "nix-tools", - "rev": "ed5bd7215292deba55d6ab7a4e8c21f8b1564dda", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "nix-tools", - "type": "github" - } - }, - "nixos-20_09": { - "locked": { - "lastModified": 1623585158, - "narHash": "sha256-AjK7M1/six8IBPOI28nm7yC2k8mZIR2F9QrOwFYHAS0=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "115dbbe82eb4ec8aabf959068286468a68e0b244", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-20.09", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixos-unstable": { - "locked": { - "lastModified": 1630248577, - "narHash": "sha256-9d/yq96TTrnF7qjA6wPYk+rYjWAXwfUmwk3qewezSeg=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "8d8a28b47b7c41aeb4ad01a2bd8b7d26986c3512", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs": { - "flake": false, - "locked": { - "lastModified": 1645493675, - "narHash": "sha256-9xundbZQbhFodsQRh6QMN1GeSXfo3y/5NL0CZcJULz0=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "74b10859829153d5c5d50f7c77b86763759e8654", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2003": { - "locked": { - "lastModified": 1620055814, - "narHash": "sha256-8LEHoYSJiL901bTMVatq+rf8y7QtWuZhwwpKE2fyaRY=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "1db42b7fe3878f3f5f7a4f2dc210772fd080e205", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-20.03-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2003_2": { - "locked": { - "lastModified": 1620055814, - "narHash": "sha256-8LEHoYSJiL901bTMVatq+rf8y7QtWuZhwwpKE2fyaRY=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "1db42b7fe3878f3f5f7a4f2dc210772fd080e205", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-20.03-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2003_3": { - "locked": { - "lastModified": 1620055814, - "narHash": "sha256-8LEHoYSJiL901bTMVatq+rf8y7QtWuZhwwpKE2fyaRY=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "1db42b7fe3878f3f5f7a4f2dc210772fd080e205", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-20.03-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2105": { - "locked": { - "lastModified": 1642244250, - "narHash": "sha256-vWpUEqQdVP4srj+/YLJRTN9vjpTs4je0cdWKXPbDItc=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "0fd9ee1aa36ce865ad273f4f07fdc093adeb5c00", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-21.05-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2105_2": { - "locked": { - "lastModified": 1642244250, - "narHash": "sha256-vWpUEqQdVP4srj+/YLJRTN9vjpTs4je0cdWKXPbDItc=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "0fd9ee1aa36ce865ad273f4f07fdc093adeb5c00", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-21.05-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2105_3": { - "locked": { - "lastModified": 1640283157, - "narHash": "sha256-6Ddfop+rKE+Gl9Tjp9YIrkfoYPzb8F80ergdjcq3/MY=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "dde1557825c5644c869c5efc7448dc03722a8f09", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-21.05-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2111": { - "locked": { - "lastModified": 1644510859, - "narHash": "sha256-xjpVvL5ecbyi0vxtVl/Fh9bwGlMbw3S06zE5nUzFB8A=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "0d1d5d7e3679fec9d07f2eb804d9f9fdb98378d3", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-21.11-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2111_2": { - "locked": { - "lastModified": 1644510859, - "narHash": "sha256-xjpVvL5ecbyi0vxtVl/Fh9bwGlMbw3S06zE5nUzFB8A=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "0d1d5d7e3679fec9d07f2eb804d9f9fdb98378d3", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-21.11-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2111_3": { - "locked": { - "lastModified": 1647902355, - "narHash": "sha256-SySJ8IRaogpc/BPOkysA+kzq9URvXthoeKIemaTKCiM=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "31aa631dbc496500efd2507baaed39626f6650f2", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-21.11-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2111_4": { - "locked": { - "lastModified": 1640283207, - "narHash": "sha256-SCwl7ZnCfMDsuSYvwIroiAlk7n33bW8HFfY8NvKhcPA=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "64c7e3388bbd9206e437713351e814366e0c3284", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-21.11-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-2111_5": { - "locked": { - "lastModified": 1644510859, - "narHash": "sha256-xjpVvL5ecbyi0vxtVl/Fh9bwGlMbw3S06zE5nUzFB8A=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "0d1d5d7e3679fec9d07f2eb804d9f9fdb98378d3", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-21.11-darwin", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-nixops": { - "locked": { - "lastModified": 1630248577, - "narHash": "sha256-9d/yq96TTrnF7qjA6wPYk+rYjWAXwfUmwk3qewezSeg=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "8d8a28b47b7c41aeb4ad01a2bd8b7d26986c3512", - "type": "github" - }, - "original": { - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "8d8a28b47b7c41aeb4ad01a2bd8b7d26986c3512", - "type": "github" - } - }, - "nixpkgs-unstable": { - "locked": { - "lastModified": 1644486793, - "narHash": "sha256-EeijR4guVHgVv+JpOX3cQO+1XdrkJfGmiJ9XVsVU530=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "1882c6b7368fd284ad01b0a5b5601ef136321292", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-unstable_2": { - "locked": { - "lastModified": 1644486793, - "narHash": "sha256-EeijR4guVHgVv+JpOX3cQO+1XdrkJfGmiJ9XVsVU530=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "1882c6b7368fd284ad01b0a5b5601ef136321292", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs-unstable_3": { - "locked": { - "lastModified": 1641285291, - "narHash": "sha256-KYaOBNGar3XWTxTsYPr9P6u74KAqNq0wobEC236U+0c=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "0432195a4b8d68faaa7d3d4b355260a3120aeeae", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_2": { - "locked": { - "lastModified": 1602411953, - "narHash": "sha256-gbupmxRpoQZqL5NBQCJN2GI5G7XDEHHHYKhVwEj5+Ps=", - "owner": "LnL7", - "repo": "nixpkgs", - "rev": "f780534ea2d0c12e62607ff254b6b45f46653f7a", - "type": "github" - }, - "original": { - "id": "nixpkgs", - "type": "indirect" - } - }, - "nixpkgs_3": { - "locked": { - "lastModified": 1633463774, - "narHash": "sha256-y3GjapcRzd42NgebQ4sx5GFJ53dYqNdF3UQu7/t6mUg=", - "owner": "hercules-ci", - "repo": "nixpkgs", - "rev": "c70f908fd1f129aede2744d4385fae57d2e252b1", - "type": "github" - }, - "original": { - "owner": "hercules-ci", - "ref": "init-nixops-hercules-ci", - "repo": "nixpkgs", - "type": "github" - } - }, - "nixpkgs_4": { - "flake": false, - "locked": { - "lastModified": 1628785280, - "narHash": "sha256-2B5eMrEr6O8ff2aQNeVxTB+9WrGE80OB4+oM6T7fOcc=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "6525bbc06a39f26750ad8ee0d40000ddfdc24acb", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixpkgs-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "old-ghc-nix": { - "flake": false, - "locked": { - "lastModified": 1631092763, - "narHash": "sha256-sIKgO+z7tj4lw3u6oBZxqIhDrzSkvpHtv0Kki+lh9Fg=", - "owner": "angerman", - "repo": "old-ghc-nix", - "rev": "af48a7a7353e418119b6dfe3cd1463a657f342b8", - "type": "github" - }, - "original": { - "owner": "angerman", - "ref": "master", - "repo": "old-ghc-nix", - "type": "github" - } - }, - "old-ghc-nix_2": { - "flake": false, - "locked": { - "lastModified": 1631092763, - "narHash": "sha256-sIKgO+z7tj4lw3u6oBZxqIhDrzSkvpHtv0Kki+lh9Fg=", - "owner": "angerman", - "repo": "old-ghc-nix", - "rev": "af48a7a7353e418119b6dfe3cd1463a657f342b8", - "type": "github" - }, - "original": { - "owner": "angerman", - "ref": "master", - "repo": "old-ghc-nix", - "type": "github" - } - }, - "old-ghc-nix_3": { - "flake": false, - "locked": { - "lastModified": 1631092763, - "narHash": "sha256-sIKgO+z7tj4lw3u6oBZxqIhDrzSkvpHtv0Kki+lh9Fg=", - "owner": "angerman", - "repo": "old-ghc-nix", - "rev": "af48a7a7353e418119b6dfe3cd1463a657f342b8", - "type": "github" - }, - "original": { - "owner": "angerman", - "ref": "master", - "repo": "old-ghc-nix", - "type": "github" - } - }, - "plutarch": { - "inputs": { - "Shrinker": "Shrinker", - "autodocodec": "autodocodec", - "cardano-base": "cardano-base", - "cardano-crypto": "cardano-crypto", - "cardano-prelude": "cardano-prelude", - "cryptonite": "cryptonite", - "flake-compat": "flake-compat_3", - "flake-compat-ci": "flake-compat-ci_3", - "flat": "flat", - "foundation": "foundation", - "haskell-language-server": "haskell-language-server_2", - "haskell-nix": "haskell-nix_4", - "hercules-ci-effects": "hercules-ci-effects", - "hs-memory": "hs-memory", - "iohk-nix": "iohk-nix_2", - "nixpkgs": [ - "plutarch", - "haskell-nix", - "nixpkgs-unstable" - ], - "nixpkgs-2111": "nixpkgs-2111_5", - "plutus": "plutus_2", - "protolude": "protolude", - "safe-coloured-text": "safe-coloured-text", - "sized-functors": "sized-functors", - "sydtest": "sydtest", - "th-extras": "th-extras", - "validity": "validity" - }, - "locked": { - "lastModified": 1648163186, - "narHash": "sha256-UfaSb4nk9HWzsj1Kb8RJuPV+iw1Nl4E2+97KOwIwcao=", - "owner": "peter-mlabs", - "repo": "plutarch", - "rev": "0638dbd706bc2c5f48f9f40be7bbe1986a778698", - "type": "github" - }, - "original": { - "owner": "peter-mlabs", - "ref": "liqwid/extra", - "repo": "plutarch", - "type": "github" - } - }, - "plutus": { - "inputs": { - "cardano-repo-tool": "cardano-repo-tool", - "gitignore-nix": "gitignore-nix", - "hackage-nix": "hackage-nix", - "haskell-language-server": "haskell-language-server", - "haskell-nix": "haskell-nix_3", - "iohk-nix": "iohk-nix", - "nixpkgs": "nixpkgs", - "pre-commit-hooks-nix": "pre-commit-hooks-nix", - "sphinxcontrib-haddock": "sphinxcontrib-haddock", - "stackage-nix": "stackage-nix" - }, - "locked": { - "lastModified": 1646401716, - "narHash": "sha256-Xh4m6NVgxhtJZPW+/TH0KncginXLORO6EAN/ulitlrw=", - "owner": "input-output-hk", - "repo": "plutus", - "rev": "73e4bbfc32ea233ba679d3f558a95adf8513a9d7", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "plutus", - "type": "github" - } - }, - "plutus_2": { - "inputs": { - "cardano-repo-tool": "cardano-repo-tool_2", - "gitignore-nix": "gitignore-nix_2", - "hackage-nix": "hackage-nix_2", - "haskell-language-server": "haskell-language-server_3", - "haskell-nix": "haskell-nix_5", - "iohk-nix": "iohk-nix_3", - "nixpkgs": "nixpkgs_4", - "pre-commit-hooks-nix": "pre-commit-hooks-nix_3", - "sphinxcontrib-haddock": "sphinxcontrib-haddock_2", - "stackage-nix": "stackage-nix_2" - }, - "locked": { - "lastModified": 1645203653, - "narHash": "sha256-HAi60mSkyMXzu1Wg3h6KdYZg+ufNMvX6obfcLo0ArL0=", - "owner": "L-as", - "repo": "plutus", - "rev": "5ec17953aae3ac9546f6d923201eb1dbb4e058bb", - "type": "github" - }, - "original": { - "owner": "L-as", - "ref": "ghc9", - "repo": "plutus", - "type": "github" - } - }, - "pre-commit-hooks-nix": { - "flake": false, - "locked": { - "lastModified": 1624971177, - "narHash": "sha256-Amf/nBj1E77RmbSSmV+hg6YOpR+rddCbbVgo5C7BS0I=", - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "rev": "397f0713d007250a2c7a745e555fa16c5dc8cadb", - "type": "github" - }, - "original": { - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "type": "github" - } - }, - "pre-commit-hooks-nix_2": { - "flake": false, - "locked": { - "lastModified": 1622650193, - "narHash": "sha256-qSzUpJDv04ajS9FXoCq6NjVF3qOt9IiGIiGh0P8amyw=", - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "rev": "0398f0649e0a741660ac5e8216760bae5cc78579", - "type": "github" - }, - "original": { - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "type": "github" - } - }, - "pre-commit-hooks-nix_3": { - "flake": false, - "locked": { - "lastModified": 1624971177, - "narHash": "sha256-Amf/nBj1E77RmbSSmV+hg6YOpR+rddCbbVgo5C7BS0I=", - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "rev": "397f0713d007250a2c7a745e555fa16c5dc8cadb", - "type": "github" - }, - "original": { - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "type": "github" - } - }, - "protolude": { - "flake": false, - "locked": { - "lastModified": 1637276813, - "narHash": "sha256-/mgR1Vyp1WYBjdkbwQycrf6lcmOgUFcYUZIMhVgYhdo=", - "owner": "protolude", - "repo": "protolude", - "rev": "d821ef0ac7552cfa2c3e7a7bdf29539f57e3fae6", - "type": "github" - }, - "original": { - "owner": "protolude", - "repo": "protolude", - "rev": "d821ef0ac7552cfa2c3e7a7bdf29539f57e3fae6", - "type": "github" - } - }, - "root": { - "inputs": { - "apropos": "apropos", - "apropos-tx": "apropos-tx", - "haskell-nix": [ - "plutarch", - "haskell-nix" - ], - "nixpkgs": [ - "plutarch", - "nixpkgs" - ], - "nixpkgs-2111": "nixpkgs-2111_3", - "plutarch": "plutarch" - } - }, - "safe-coloured-text": { - "flake": false, - "locked": { - "lastModified": 1644357337, - "narHash": "sha256-sXSKw8m6O9K/H2BBiYqO5e4sJIo+9UP+UvEukRn28d8=", - "owner": "srid", - "repo": "safe-coloured-text", - "rev": "034f3612525568b422e0c62b52417d77b7cf31c2", - "type": "github" - }, - "original": { - "owner": "srid", - "ref": "ghc921", - "repo": "safe-coloured-text", - "type": "github" - } - }, - "sized-functors": { - "flake": false, - "locked": { - "lastModified": 1620614934, - "narHash": "sha256-pVJbEGF4/lvXmWIypwkMQBYygOx3TQwLJbMpfdYovdY=", - "owner": "JonasDuregard", - "repo": "sized-functors", - "rev": "fe6bf78a1b97ff7429630d0e8974c9bc40945dcf", - "type": "github" - }, - "original": { - "owner": "JonasDuregard", - "repo": "sized-functors", - "rev": "fe6bf78a1b97ff7429630d0e8974c9bc40945dcf", - "type": "github" - } - }, - "sphinxcontrib-haddock": { - "flake": false, - "locked": { - "lastModified": 1594136664, - "narHash": "sha256-O9YT3iCUBHP3CEF88VDLLCO2HSP3HqkNA2q2939RnVY=", - "owner": "michaelpj", - "repo": "sphinxcontrib-haddock", - "rev": "f3956b3256962b2d27d5a4e96edb7951acf5de34", - "type": "github" - }, - "original": { - "owner": "michaelpj", - "repo": "sphinxcontrib-haddock", - "type": "github" - } - }, - "sphinxcontrib-haddock_2": { - "flake": false, - "locked": { - "lastModified": 1594136664, - "narHash": "sha256-O9YT3iCUBHP3CEF88VDLLCO2HSP3HqkNA2q2939RnVY=", - "owner": "michaelpj", - "repo": "sphinxcontrib-haddock", - "rev": "f3956b3256962b2d27d5a4e96edb7951acf5de34", - "type": "github" - }, - "original": { - "owner": "michaelpj", - "repo": "sphinxcontrib-haddock", - "type": "github" - } - }, - "stackage": { - "flake": false, - "locked": { - "lastModified": 1646270328, - "narHash": "sha256-WFzBTbZW9zKnZtHLBLGui9F1tBDKX7ixBtaQOG5SK/M=", - "owner": "input-output-hk", - "repo": "stackage.nix", - "rev": "b3171527569b52b3924d8e70e0aed753d3f55cc4", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "stackage.nix", - "type": "github" - } - }, - "stackage-nix": { - "flake": false, - "locked": { - "lastModified": 1597712578, - "narHash": "sha256-c/pcfZ6w5Yp//7oC0hErOGVVphBLc5vc4IZlWKZ/t6E=", - "owner": "input-output-hk", - "repo": "stackage.nix", - "rev": "e32c8b06d56954865725514ce0d98d5d1867e43a", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "stackage.nix", - "type": "github" - } - }, - "stackage-nix_2": { - "flake": false, - "locked": { - "lastModified": 1597712578, - "narHash": "sha256-c/pcfZ6w5Yp//7oC0hErOGVVphBLc5vc4IZlWKZ/t6E=", - "owner": "input-output-hk", - "repo": "stackage.nix", - "rev": "e32c8b06d56954865725514ce0d98d5d1867e43a", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "stackage.nix", - "type": "github" - } - }, - "stackage_2": { - "flake": false, - "locked": { - "lastModified": 1646270328, - "narHash": "sha256-WFzBTbZW9zKnZtHLBLGui9F1tBDKX7ixBtaQOG5SK/M=", - "owner": "input-output-hk", - "repo": "stackage.nix", - "rev": "b3171527569b52b3924d8e70e0aed753d3f55cc4", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "stackage.nix", - "type": "github" - } - }, - "stackage_3": { - "flake": false, - "locked": { - "lastModified": 1642468901, - "narHash": "sha256-+Hu4m9i8v8Moey/C8fy8juyxB729JdsXz02cK8nJXLk=", - "owner": "input-output-hk", - "repo": "stackage.nix", - "rev": "7544f8fd16bb92b7cf90cb51cb4ddc43173526de", - "type": "github" - }, - "original": { - "owner": "input-output-hk", - "repo": "stackage.nix", - "type": "github" - } - }, - "sydtest": { - "flake": false, - "locked": { - "lastModified": 1645114028, - "narHash": "sha256-P6ZwwfFeN8fpi3fziz9yERTn7BfxdE/j/OofUu+4GdA=", - "owner": "srid", - "repo": "sydtest", - "rev": "9c6c7678f7aabe22e075aab810a6a2e304591d24", - "type": "github" - }, - "original": { - "owner": "srid", - "ref": "ghc921", - "repo": "sydtest", - "type": "github" - } - }, - "th-extras": { - "flake": false, - "locked": { - "lastModified": 1641329261, - "narHash": "sha256-+K91xH/zew66ry0EAV5FaEIAHUZdJ3ngD9GzCJiUq7k=", - "owner": "mokus0", - "repo": "th-extras", - "rev": "787ed752c1e5d41b5903b74e171ed087de38bffa", - "type": "github" - }, - "original": { - "owner": "mokus0", - "repo": "th-extras", - "rev": "787ed752c1e5d41b5903b74e171ed087de38bffa", - "type": "github" - } - }, - "validity": { - "flake": false, - "locked": { - "lastModified": 1644358698, - "narHash": "sha256-dpMIu08qXMzy8Kilk/2VWpuwIsfqFtpg/3mkwt5pdjA=", - "owner": "srid", - "repo": "validity", - "rev": "f7982549b95d0ab727950dc876ca06b1862135ba", - "type": "github" - }, - "original": { - "owner": "srid", - "ref": "ghc921", - "repo": "validity", - "type": "github" - } - } - }, - "root": "root", - "version": 7 -} diff --git a/flake.nix b/flake.nix index b8e728c..0583055 100644 --- a/flake.nix +++ b/flake.nix @@ -11,11 +11,19 @@ inputs.plutarch.inputs.nixpkgs.follows = "plutarch/haskell-nix/nixpkgs-unstable"; - # https://github.com/mlabs-haskell/apropos-tx/pull/28 + # Follows jhodgdev's forks of apropos and apropos-tx, as these + # are not constrained to `base ^>= 4.14`. Once these are merged + # to their respective master branches, we should change the + # inputs to follow a commit on those master branches. For more + # info, see: https://github.com/mlabs-haskell/apropos-tx/pull/37 inputs.apropos-tx.url = "github:jhodgdev/apropos-tx?rev=4eca3fac23c339caee04ea6176e641a4b3857a25"; inputs.apropos-tx.inputs.nixpkgs.follows = "plutarch/haskell-nix/nixpkgs-unstable"; + inputs.apropos.url = + "github:jhodgdev/apropos?rev=c6c580aeab8b5c2a6512a49823dd17936e87b70a"; + inputs.apropos.inputs.nixpkgs.follows = + "plutarch/haskell-nix/nixpkgs-unstable"; inputs.apropos.url = "github:mlabs-haskell/apropos?rev=3734bb3baa297ed990725a5ef14efcbb6a1c1c23"; @@ -93,6 +101,7 @@ ps.plutarch-extra ps.plutarch-numeric ps.plutarch-test + ps.apropos ]; }; }; diff --git a/hie.yaml b/hie.yaml index e1be10a..6020af6 100644 --- a/hie.yaml +++ b/hie.yaml @@ -1,6 +1,6 @@ cradle: cabal: - - path: "./agora-src" + - path: "./agora" component: "lib:agora" - path: "./agora-bench" component: "benchmark:agora-bench"