mirror of
https://github.com/FiloSpaTeam/plutus-pioneer-program.git
synced 2024-12-22 21:42:11 +01:00
No description
fbf2cf4a67
Update README.md |
||
---|---|---|
code | ||
README.md |
Plutus Pioneer Program
Lectures
-
- Welcome
- The (E)UTxO-model
- Running an example auction contract on a local Playground
- Homework
-
- Triggering change.
- Low-level, untyped on-chain validation scripts.
- High-level, typed on-chain validation scripts.
-
- Script context.
- Time handling.
- Parameterized contracts.
-
- Monads
- The
EmulatorTrace
monad. - The
Contract
monad.
Code Examples
- Lecture #1: English Auction
- Lecture #2: Simple Validation
- Lecture #3: Validation Context & Parameterized Contracts
- Lecture #4: Monads,
EmulatorTrace
&Contract
Exercises
-
Week #1
- Build the English Auction contract with
cabal build
(you may need to runcabal update
first). - Clone the The Plutus repository, check out the correct commit as specified in cabal.project.
- Set-up IOHK binary caches How to set up the IOHK binary caches. "If you do not do this, you will end up building GHC, which takes several hours. If you find yourself building GHC, STOP and fix the cache."
- Enter a
nix-shell
. - Go to the
plutus-playground-client
folder. - Start the Playground server with
plutus-playground-server
. - Start the Playground client (in another
nix-shell
) withnpm run start
. - Copy-paste the auction contract into the Playground editor - don't forget to remove the module header!
- Compile.
- Simulate various auction scenarios.
- Build the English Auction contract with
-
Week #2
-
Week #3
-
Week #4
- Write an appropriate
EmulatorTrace
that uses thepayContract
contract in the Homework module. - Catch errors in the
payContract
contract in the same module.
- Write an appropriate
Solutions
Some Plutus Modules
Plutus.Trace.Emulator
, contains types and functions related to traces.Plutus.V1.Ledger.Contexts
, contains the definition of the context-related types.Plutus.V1.Ledger.Interval
, contains the definition of and helper functions for theInterval
type.Plutus.V1.Ledger.Slot
, contains the definition of theSlot
type.PlutusTx.Data
, contains the definition of theData
type.PlutusTx.IsData.Class
, defines theIsData
class.
Plutus community playground
- Week 1 Community Playground(Legacy)
- Week 2 Community Playground(Legacy)
- Week 3 Community Playground(Current)
- Week 4 Community Playground(Current)