Giter Site home page Giter Site logo

plutus-experimental-smart-contracts's Introduction

Plutus Experimental Smart Contacts

This repo holds smart contracts which I am writing in order to experiment with the Plutus Platform. They are very likely to have obvious oversights and may be easily abused. This is on purpose as they are designed to test specific ideas, not to be perfectly implemented or safe to use. Thus when mainnet launches, do not use these.

However feel free to hop on over to the Plutus Playground to test the code out for yourself: https://prod.playground.plutus.iohkdev.io/

plutus-experimental-smart-contracts's People

Contributors

robkorn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

plutus-experimental-smart-contracts's Issues

Commenting on what each line does

More of a suggestion than issue, but it would be awesome if you could comment what each line is doing and why in the context of the smart contract objective. Lots of comments can really help when it’s a learning piece of code 👍

compilation errors

Line 14, Column 53:

error:
• Not in scope: data constructor ‘PendingTx'’
Perhaps you meant one of these:
‘PendingTx’ (imported from Ledger.Validation),
‘PendingTxIn’ (imported from Ledger.Validation),
‘PendingTxOut’ (imported from Ledger.Validation)
• In the Template Haskell quotation
[|| \ (submittedPIN :: Int) (myPIN :: Int) (p :: 'PendingTx')
-> if submittedPIN == myPIN then
()
else
$$(P.error)
($$(P.traceH)
"Please supply the correct PIN number to withdraw ada." ()) ||]
In the typed splice:
$$(PlutusTx.compile
[|| \ (submittedPIN :: Int) (myPIN :: Int) (p :: 'PendingTx')
-> if submittedPIN == myPIN then
()
else
$$(P.error)
($$(P.traceH)
"Please supply the correct PIN number to withdraw ada." ()) ||])
|
14 | [|| (submittedPIN :: Int) (myPIN :: Int) (p :: 'PendingTx') ->
| ^^^^^^^^^^^
jump
Line 20, Column 25:

error:
Not in scope: type constructor or class ‘Address'’
Perhaps you meant one of these:
‘Address’ (imported from Ledger),
‘AddressOf’ (imported from Ledger)
|
20 | smartContractAddress :: Address'
| ^^^^^^^^

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.