Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.

Questions tagged [contract-deployment]

The act of pushing a compiled smart contract in byte code to the Ethereum blockchain.

Filter by
Sorted by
Tagged with
9
votes
4answers
4k views

Passing constructor arguments while deploying contract from byte code

I am trying to deploy a contract via MyEtherWallet from byte code generated by browser-solidity. I unlocked my wallet using private key,but I didn't find any way of passing parameters to contract's ...
9
votes
1answer
2k views

How to edit a contract that has already been deployed? [duplicate]

I have been writing my first few contracts. So, as I understand it, once you write, compile, and deploy your contract, the only way to then interact with that contract is via something like web3.js ...
23
votes
6answers
13k views

Truffle deployment on test network says: Error: exceeds block gas limit

I'm trying to deploy a sample contract (following this guide) but I'm receiving an error of not enough gas. I changed the numbers a little but could not fix it. I saw this question in stack exchange ...
3
votes
1answer
2k views

Max possible ERC20 Tokens allowed with 18 decimals?

I would like my token to have the maximum possible amount of tokens issued as a novelty. I would like to use 18 decimals standard ERC20 token, what value can I put in to get the maximum amount of ...
3
votes
1answer
2k views

Error: “The contract code couldn't be stored, please check your gas limit” [duplicate]

It's seem that is a very common topic but I couldn't find the solution in other questions, sorry for asking it again. I'm following a beginner example, trying to deploy a contract in Rinkeby Network ...
10
votes
2answers
1k views

Programmatically saving the contract address of a submitted contract

I understand how the below web3js code block works, adapted from here: https://github.com/ethereum/wiki/wiki/JavaScript-API#web3ethcontract But how does one save the contract address ...
9
votes
2answers
2k views

Truffle: Hanging on “Deploying Migrations…”

I am deploying a contract on a private testnet. I am using Parity. When I type: $ truffle migrate --network my-network-name I get a popup in the Parity interface for a password to my account. I ...
9
votes
3answers
3k views

Deploy contract on EthereumJS TestRPC

Following https://medium.com/@mvmurthy/full-stack-hello-world-voting-ethereum-dapp-tutorial-part-1-40d2d0d807c2 I've tried to create an instance of a contract using: VotingContract = web3.eth....
8
votes
3answers
2k views

Truffle migration stuck

I am trying to migrate contract on a block chain network created using azure ethereum consortium blockchain, But when I am running the command Truffle migrate it stuck at PS D:\sl\BCSLAC\bcdemo\sol&...
7
votes
1answer
783 views

Deploy contract in web3j quorum problem

I'm trying to deploy a smart contract (7 nodes sample from Quorum) using web3j. It fails at get() to get the contract wrapper object. If I check the logs, a new transaction will show up, but if I call ...
5
votes
1answer
2k views

How to install solidity in Visual Studio?

I see microsoft visual studio now supports solidity and smart contracts deployments. The release notes state: Creates project scaffolding with smart contract samples Supports context sensitive menus ...
1
vote
0answers
241 views

How to find constructor values being passed to a contract

I'd like to find out which values were passed in when someone deployed a CrowdSale token. Is there a way to find out. Here is Lunyr Crowdsale contract How would I find out which values they passed ...
6
votes
2answers
846 views

Generate contract address using nonce

Good day, I was looking at the way contracts addresses are created and it seems that the process is quite deterministic (depends on the nonce). Is there a way to get the address of a contract that ...
6
votes
2answers
535 views

How many Ethereum contracts have been published?

Is there a place to see how many Ethereum contracts have been published? If someone wanted to calculate that, it would just be total number of accounts minus accounts with code, right? Any ...
5
votes
2answers
3k views

Deploying contracts in Ropsten with Truffle

I have another n00b question... sorry about that :( I'm trying to deploy a smart contract to Ropsten. I have synched the Ropsten network with geth --testnet --fast --rpc --rpcapi eth,net,web3,...
4
votes
2answers
2k views

Contract deployment throws block gas limit error

I'm trying to deploy a smart contract in a test network, using a [meteor DApp][1]. I have this parameters for the genesis block: gasLimit: "0x1388" However, any time I try to deploy any single ...
4
votes
1answer
2k views

Exceeds gas block limit error when deploying near block gas limit contract

I'm trying to create a wallet contract using Geth 1.5 --light and Mist Wallet 0.8.7. Estimated gas cost for the contract creation is 1,962,239 while the gas limit is 1,998,227. So, everything should ...
4
votes
1answer
523 views

How do you provide a GasPrice and GasLimit to overcome the “low tx nonce or out of funds” log message

I am getting the following logged by my private chain geth node when running a test in truffle: removed tx ( TX(ff8ec4f713e64fb25df07d153607e29629c9276b57e0b7e331f17b5a3c31fdd1) Contract: ...
4
votes
1answer
4k views

How to specify the gas when deploying a new contract in Mist?

When I send transactions to my contract, the wallet tells me that the gas runs out, so how can I specify the gas amount when deploy a new contract?
3
votes
1answer
458 views

Should callbacks be called twice from both MyContract.new and MyContract.myFunction on web3 API?

When I instantiate a contract with myContract.new() like this: MyContract.new({ from: addr, data: code, gas: gas, gasPrice: price }, function (error, contract) { if (!error) { ...
3
votes
2answers
1k views

Truffle on Windows 10: how to unlock an account for migration to a private network

I try to migrate a smart contract to a private network via truffle on Windows 10. I specify a certain account in truffle.js and so far I get the following error: Error encountered, bailing. Network ...
3
votes
1answer
461 views

No data is deployed in the contract address

I have followed the previous solutions to this problem as mentioned in this question: Mist: "No data is deployed on the contract address!" I also checked if the Estimated consumption fee ...
3
votes
1answer
909 views

Deploy a contract from Solidity Browser or geth on an external node(connected into private ethereum blockchain)

I am trying to deploy a Contract from Solidity browser || geth. On my server machine, inside solidity browser || geth I am able to deploy a contract. But from my external node, which is connected into ...
2
votes
2answers
741 views

Why do contracts start with nonce 1?

This is a follow-up to this question. The accepted answer says: Yes, contracts have nonces. A nonce of a contract is only incremented when that contract creates another contract [...]. When a ...
1
vote
1answer
350 views

Ethereum Solidity how to deploy a contract from another contract with constructor function

The old way: constructor function is the same as the contract name: contract CtrtFactory { function makeCtrt() { address ctrtAddress = new Ctrt(...); } } contract Ctrt() { function Ctrt(..) ...
1
vote
1answer
287 views

Faster deployment of contracts using geth

I'm working with a fairly large contract (~12 KB) on a private test net and deployment times are quite large (not mining the contract, but copying the interface and creating the deployment transaction ...
1
vote
1answer
2k views

How to verify a contract having constructor arguments?

This is a contract that requires an argument to be deployed. The Contract Name is "Asset". The compiler used is "Compiler 0.4.16+commit.d7661dd9.Emscripten.clang" and Optimization was Disabled. To ...
1
vote
1answer
261 views

Gas Consuption: Deploying contracts from within a contract

I have a contract A that does nothing other than allowing to deploy contracts B and C in functions. Deployment of A exceeds gas limit. Seperate deployment of B and C work fine. So my naive assumption ...
1
vote
1answer
54 views

Why does the contract deployment code of a specific contract saves an address to storage? [closed]

The contract in question can be found on the mainnet at https://etherscan.io/address/0x61dc347d7fA0f6e34c3112fAF83a2e468D681F68#code. This looks too good to be true, free money, so something must be ...
0
votes
1answer
74 views

How to interface with a deployed Ethereum smart contract?

I want to create an interface to interact with my smart contract. I have got an example from the following link. Counter Before implementing my contract, I have tried to use the given example.But it ...
0
votes
1answer
479 views

How to interact with a smart contract in practice (for free)? A bigger picture!

At the moment I'm learning Solidity and using online remix to practice coding. Question 1: As an exercise, can I construct a transaction and invoke my contract, for free (without inserting my ...
8
votes
2answers
356 views

When a smart contract is deployed, is its source code publicly viewable?

When a smart contract is deployed to the blockchain, is the source code then publicly viewable to all participants? For example, what you see here in Etherchain. I am aware that there are some ...
5
votes
1answer
8k views

Solidity compiler is giving error ( Expected token Semicolon got 'RBrace' )

I am compiling a contract from browser-solidity,but I am getting Error: Expected token Semicolon got 'RBrace' . The part of contract that throws error is: contract owned { address public owner; ...
5
votes
1answer
411 views

Unable to deploy contract on public chain

I was trying to deploy a contract to public ethereum network using Mist. I was able to send transaction successfully but my transaction is get no confirmations. It has been around 45 minutes and my ...
5
votes
1answer
541 views

Do you need to publish the contract ABI and address for others to interact with the contract?

Suppose you write a contract that you want others to interact with. My understanding is that if you want others to interact with your contract, you need to provide the contract's ABI and address. Is ...
4
votes
1answer
943 views

How to deploy dependent contracts with Ethereum Wallet

I have two contracts (i.e. contractA, contractB) located in different files (i.e, contractA.sol, contractB.sol) to deploy. The contractB is dependent on contractA. In contractB.sol, import "...
4
votes
1answer
970 views

Truffle Dapp Deployed Contract Access

Which function we need to use in truffle for the communication of second Dapp to the contract deployed on blockchain by first Dapp, because contract deployed by truffle is not accessible by geth node. ...
4
votes
1answer
1k views

How to minimize gas consumption during contract creation

I have trouble deploying a contract to the main network and I believe this is due to high gas consumption. An earlier version of the contract worked on the main network. The current version works in ...
4
votes
2answers
605 views

Importing a contract from another contract in NodeJS app

I'm using a function in my NodeJS app to deploy contracts. The user inputs the contract he wishes to deploy and the app deploys it. The structure of the app is . ├── app │   ├── models │   │   └── ...
4
votes
1answer
5k views

Constructing contract with an address array

Please correct me if I am wrong but I understand you cannot initialise a contract with a string array as it is a dynamic type but can I initalise a contract with a fixed type? specifically an array of ...
4
votes
3answers
1k views

Deploying contracts on geth returns Error: connect ECONNREFUSED 127.0.0.1:8545

I'm using truffle (which uses pudding) to deploy contracts to my testrpc. No I'm running a geth instance locally with: geth --mine -rpccorsdomain "*" --ipcapi "admin,eth,miner" --rpcapi "eth,...
4
votes
2answers
1k views

truffle deploy to geth failing, generating “receipt not found” repeatedly from geth

I've just installed truffle on an ubuntu virtualbox, and it is failing to deploy to a geth dev setup. Geth gives me a never-ending receipt not found for transaction ...
3
votes
1answer
269 views

Could I give higher priority to transactions to mined right away?

For example on Linux we can give higher priority to processes for Linux Kernel to schedule. I am the owner of my Private Ethereum Network. As an owner, could I give higher priority to deploy or mine ...
3
votes
2answers
456 views

Can the CALL opcode be used to create a contract?

The Yellow Paper Appendix H defines the CREATE and CALL opcodes. For CALL: the operand order is: gas, to, value, in offset, in size, out offset, out size. By setting the second operand (the "to"...
3
votes
1answer
331 views

What will be the format of data to execute a function from web

I have deployed a cryptocurrent on Private testNet from here. I have deployed two contracts, lets call them contract1 and contract2. Contract1 has less features than contract2 (like transferFrom() ...
3
votes
2answers
219 views

Where to find the private key for my contract in blockapps?

I am trying to use blockapps-js to invoke functions on my smart contract deployed in blockapps. Since I need the private key for it, I am looking at the app/users/admin/.json file. Problem is I cannot ...
2
votes
1answer
2k views

Deploying contract with parameters using web3.js and Node.js

I try to deploy a ERC721 contract. Which is from OpenZeppelin. My contract constructor wants two input string fields. constructor(string _name, string _symbol) public { name_ = _name; ...
2
votes
2answers
217 views

Why do people hash the address?

I recently saw a smart contract where the user used keccak256(address), is there any reason to do this, instead of just storing the address in the mapping?
2
votes
4answers
727 views

use web3js and infura deploy contract

const Web3 = require('web3'); const fs = require('fs'); const solc = require('solc'); let web3; if (typeof web3 !== 'undefined') { web3 = new Web3(web3.currentProvider); } else { web3 = new ...
2
votes
1answer
872 views

Ethereum Wallet: error of no key for given address or file

In etherum wallet I am getting an error of no key for given address or file during deployment of the contract. What will be the reason for the same? contract User{ string public userName; ...