Questions tagged [plutus]

Plutus Platform is the smart contract platform of the Cardano blockchain. Plutus contracts consist of pieces that run on the blockchain (on-chain code) and pieces that run on a user’s machine (off-chain or client code)

The Plutus Platform is the smart contract platform of the Cardano blockchain. Plutus contracts consist of pieces that run on the blockchain (on-chain code) and pieces that run on a user’s machine (off-chain or client code).

Both on-chain and off-chain code is written in Haskell, and Plutus smart contracts are Haskell programs. Off-chain code is compiled by GHC, the Haskell compiler, and on-chain code is compiled by the Plutus compiler.

Plutus Documentation.

19 questions
3
votes
0 answers

Is there any way to copy Haskell binaries to another project to save time on initial build?

I'm working on learning to build DApps on Cardano with Plutus, which is built in Haskell. I've found that the initial cabal build for a project takes quite a long time, usually 30+ minutes, even if the cabal packages are cached on my local machine…
marcel_g
  • 1,980
  • 2
  • 17
  • 19
2
votes
1 answer

Plutus Interpreter Error in Plutus Playground

This code compiles but when I click on Evaluate I get this error. I'm not sure if this is from the playground or not because I used the same code from their new tutorial . The error doesn't show up when I compile it only happens when I attempt view…
jnprogrammer
  • 153
  • 1
  • 3
  • 9
2
votes
3 answers

Can't find nix-env or nix-build on MacOS Catalina

I can't find nix-env, nix-build, nix-shell etc. on MacOS Catalina. I installed with: sh <(curl https://nixos.org/nix/install) --darwin-use-unencrypted-nix-store-volume and was able to run them yesterday. I restarted my computer and can no longer…
Max Heiber
  • 14,346
  • 12
  • 59
  • 97
1
vote
0 answers

Problem running Plutus Playground Client on MacOS

I am encountering a problem when trying to run the Plutus Playground through Nix on MacOS. I tried using the last available tag v2021-12-20, but I am getting the following error when I try to run the Plutus Playground Client in…
Matt59
  • 11
  • 1
1
vote
0 answers

Plutus Playground Client cannot run

I am trying to run plutus-playground-client, but I get this error when I run npm run start [nix-shell:~/dev/plutus/plutus-playground-client]$ npm run start > plutus-playground-client@1.0.0 start /Users/danicuki/dev/plutus/plutus-playground-client >…
Daniel Cukier
  • 11,502
  • 15
  • 68
  • 123
1
vote
1 answer

Typed version of Plutus Pionneers homework01 (week02)

I've tried to code a typed version of the first homework exercise. It compiles but fails to render in the playground... {-# LANGUAGE DataKinds #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE NoImplicitPrelude #-} {-# LANGUAGE…
regisg
  • 158
  • 5
1
vote
0 answers

How to implement counter game with state in cardano plutus? (the 10th player can pick reward)

I want to make a simple stateful game in cardano using plutus language (to check what is possible in cardano, and what is not) The rules are the following: contract creator deploys smart contract and locks some ADA games call the smart contract the…
srghma
  • 4,770
  • 2
  • 38
  • 54
1
vote
1 answer

Why do we need `startWatching` function from WalletApi?

In plutus playground in game example there is a function -- | The "startGame" contract endpoint, telling the wallet to start watching -- the address of the game script. See note [Contract endpoints] startGame :: MonadWallet m => m () startGame = …
srghma
  • 4,770
  • 2
  • 38
  • 54
0
votes
0 answers

What is different nami wallet signing and payment.skey signing?

I built transaction at nodejs by using cardano-cli. cardano-cli transaction build \ --alonzo-era \ --testnet-magic 1 \ --tx-in dbf7f56f844cc4b85daccb62bedf4eeff0a84cb060f0f79b206c7f087b3f0ba1#0 \ --tx-in…
Lovely
  • 306
  • 2
  • 12
0
votes
0 answers

Unable to start plutus-playground-server

After having to completely setup development environment. Attempting to run the backend server "plutus-playground-server" in nix.shell. I got this I installed nix.shell then I cloned the plutus-app reprository and also cd…
0
votes
0 answers

strange cabal build behaviour - won't detect changes to code files

This might have something to do with me working in a docker container, that is an ubuntu version of linux, with nix installed and plutus-starter cloned. I'm currently updating a plutus script I wrote based on an older version of plutus-starter, so…
marcel_g
  • 1,980
  • 2
  • 17
  • 19
0
votes
1 answer

Vesting via Cardano smart contract fails if receiver wallet is empty

Assume vesting code block in Plutus playground. Simply, if receiver wallet has some ADA, the contract works normally. But in case of an empty receiver wallet, transaction will fail because sending money from script to wallet needs an amount of fee…
weera
  • 884
  • 1
  • 10
  • 21
0
votes
1 answer

How to divide amount unequally in Plutus Smart Contracts

I need to make a smart contract using Plutus to divide an amount to 2 wallet unequally so I can define custom fees for each transaction. I am using this documentation. What I need is that I would like to split the amount to two unequal amounts and…
weera
  • 884
  • 1
  • 10
  • 21
0
votes
1 answer

How to set HTTP version with Haskell request

I'm working through the first iteration of the Plutus Pioneer Lectures, and the code for lecture 6 that gets the exchange rate from coinmarketcap.com returns a 403 error: getExchangeRate = runReq defaultHttpConfig $ do v <- req GET …
marcel_g
  • 1,980
  • 2
  • 17
  • 19
0
votes
2 answers

PlutusPlayground [high REDEEM fees]

I'm learning writing smart contracts in the PlutusPlayground and am getting excessively high fees when redeeming tokens from the example scripts (over 3000 ADA). Does anyone know why this might happen? I've seen a couple tutorials going through…
MapMoTa
  • 41
  • 4
1
2