Skip to main content

Questions tagged [plutustx]

The tag has no usage guidance.

13 votes
1 answer
324 views

How do I build a debug configuration of a Plutus project?

When I try to set a breakpoint in a small Plutus project such as this, I always get the following error: :b Week05.Homework1.mkPolicy cannot set breakpoint on Week05.Homework1.mkPolicy: module Week05....
thebrandre's user avatar
7 votes
1 answer
302 views

How does `submitTxConstraintsWith` make usage of the ScriptLookups?

submitTxConstraintsWith :: ScriptLookups a -> TxConstraints (RedeemerType a) (DatumType a) -> Contract w s e Tx How does submitTxConstraintsWith make usage of the ScriptLookups? I always see it ...
Attilah's user avatar
  • 381
5 votes
1 answer
421 views

What does @ prefix means?

like this: auctionInstance = Scripts.validator @Auctioning and Hello-world app from https://playground.plutus.iohkdev.io/tutorial/tutorials/plutus-playground.html#running-the-hello-world-app hello = ...
mackie's user avatar
  • 343
4 votes
1 answer
148 views

How to calculate fees for Plutus Smart Contract?

How can someone calculate fee for executing Plutus smart contract given that they know CPU and Memory Units required for executing Plutus Script?
pyropy's user avatar
  • 641
4 votes
2 answers
172 views

(Lecture #6 It #2 - Core.Hs) : Explaining lookups use of both typedValidatorLookups and otherScript?

Can somebody explain these lines and why (both) Constraints.typedValidatorLookups... and Constraints.otherScript... are used? Still struggling to get my head around lookups, so maybe that is why I'm ...
ZachSweet's user avatar
  • 178
4 votes
1 answer
249 views

Writing basic validator scripts

I need someone to explain to me line by line. The code is from plutu tutorials. https://docs.cardano.org/projects/plutus/en/latest/plutus/tutorials/basic-validators.html All the code in that page I ...
mackie's user avatar
  • 343
3 votes
2 answers
530 views

What exactly is the script context in Plutus context?

I believe the best way to answer this question would be to give examples of the type of information that the script context could contain.
FTM's user avatar
  • 294
3 votes
1 answer
789 views

What are the benefits of using Plutarch?

Is Plutarch a good replacement for Plutus Tx? https://github.com/Plutonomicon/plutarch/blob/master/docs/GUIDE.md
Attilah's user avatar
  • 381
3 votes
1 answer
219 views

Couldn't match expected type ‘BuiltinData’ in locally run playground

Working through the Plutus Pioneer Week2 homework and getting the following error in the locally served playground. error: • Couldn't match expected type ‘BuiltinData’ with ...
alanionita's user avatar
3 votes
1 answer
137 views

Unclear error during Plutus ScriptContext construction (force headList [])

I ran into an error while trying to autobalance a transaction body: module Foo.Offchain where import Plutus.V1.Ledger.Scripts (MintingPolicy) import Plutus.V1.Ledger.Address (Address) import Hydra....
SwiftlyUnmoving's user avatar
3 votes
1 answer
164 views

How can I secure a Datum value in a smart contract?

I am trying to figure out how to write a script where you can make sure the datum value doesn't change each time an output gets consumed. For example, in the auction script in the pioneer program each ...
noone392's user avatar
  • 263
3 votes
1 answer
170 views

Constraints.mustPayToPubKey requires txSignedBy?

For a contract, I want to use Constraints.mustPayToPubKey for an arbitrary pubKeyHash (pkh), such as a lucky winner in a lottery. Question: Does the validator need to check that the transaction sees ...
Kwaggy's user avatar
  • 400
3 votes
1 answer
125 views

Canonical example of Smart Contract Verification?

Given that the chief benefit of Cardano Smart Contracts over Ethereum Smart Contracts is formal verification (and thus its implied validity, security, and robustness), is there a non-trivial example ...
Michael Daconta's user avatar
3 votes
2 answers
90 views

plutus pioneer week01 src code explain

I'm a little confused about the following code(from EnglishAuction.hs): auctionInstance :: Scripts.ScriptInstance Auctioning auctionInstance = Scripts.validator @Auctioning $$(PlutusTx.compile [|| ...
mackie's user avatar
  • 343
2 votes
1 answer
92 views

Is it possible to not compile data constructors with plutus-tx?

I'm having a newtype VerificationKey = HydraVerificationKey (VerKeyDSIGN Ed25519DSIGN) and I would love to be able to use that type directly in our plutus scripts. While I can implement PlutusTx....
Sebastian Nagel's user avatar

15 30 50 per page