Questions tagged [truffle-migration]

Truffle Migrations are JavaScript files that help you deploy contracts to the Ethereum network. These files are responsible for staging your deployment tasks, and they're written under the assumption that your deployment needs will change over time. As your project evolves, you'll create new migration scripts to further this evolution on the blockchain.

Filter by
Sorted by
Tagged with
0
votes
1answer
15 views

Contract has not been not deployed to detected network

I'm trying to access a smart contract in my local dev environment, but it doesn't appear to be deploying fully. In summary, I get what seems to be a successful migration, however, I am not able to ...
0
votes
0answers
11 views

Unable to deploy contract using Truffle on local network Geth : “ProxyAdmin” hit an invalid opcode while deploying

I am trying to deploy a simple contract using truffle on my local Geth network. But it is throwing the following error: Santanu@ITS-7 MINGW64 /d/xampp/htdocs/truffle_nft_example_nuxt (main) > ...
0
votes
0answers
40 views

Error with Truffle React (the contract doesn't have address)

Someone knows something about this error with Truffle React box? Must be my Metamask wallet address but it is already in my truffle-config file. I leave the App.js file here (I didn't make it. It's ...
0
votes
2answers
13 views

Contract is NOT deployed Despite calling truffle migrate

I'm trying to call a contract I've created. I've set up my truffle deployment script like so: var SafeYieldAggregator = artifacts.require("SafeYieldAggregator") module.exports = function(...
0
votes
1answer
17 views

The second contract is not getting deployed in migration

const Input = artifacts.require("Input"); const Register = artifacts.require("Register"); module.exports = function (deployer) { deployer.deploy(Input, "test_name") ....
0
votes
0answers
29 views

Cannot find module web3

I've tried npm install web3 already but it didn't work. I suspect that this Chainlink deployment does not come with the web3 configuration files, is that possible? For example, in another Truffle ...
0
votes
2answers
32 views

Cannot find module '@chainlink/contracts/truffle/v0.4/LinkToken'

I was following these steps in order to use Chainlink on Kovan testnet. when I've finished the configuration (truffle-config.js, npm install to get all the dependencies, etc.) and I've compiled the ...
0
votes
0answers
16 views

Truffle incompatible with ESMs (ES5 / ES6 modules with “type”: “module” in package.json)?

is it possible to execute truffle commands inside a folder in "ESM mode", i.e. package.json contains "type": "module", uses import instead of require etc.? Here is what I ...
0
votes
1answer
21 views

How to deploy a new version of a smart contract to a testnet?

So I have deployed a contract to the Rinkeby testnet but I have added some new features to it and I've tried deploying the contract again but it just says the following: √ Fetching solc version list ...
1
vote
0answers
25 views

Error in Ropsten: The network id specified in the truffle config (3) does not match the one returned by the network (1)

There are similar questions but I could not find the solution. maybe because smart contract tools are developing so fast. here is the setting for ropsten in truffle config. ropsten: { ...
0
votes
1answer
9 views

When migrating truffle second time, I get “Could not connect to your Ethereum client with the following parameters:”

When I first run truffle migrate yesterday, it worked. But today I am getting this error: - host > 127.0.0.1 - port > 8545 - network_id > * Please check that your Ethereum client: ...
0
votes
1answer
22 views

Truffle compiler version not changing

truffle.js: var HDWalletProvider = require("truffle-hdwallet-provider"); var mnemonic = ""; module.exports = { networks: { testnet: { provider: () => new ...
0
votes
0answers
20 views

Truffle Test - migration and test deploy contracts but test uses the parameter of migrations

I rage with this messed up truffle suit :D I have two contracts. One contract is owner of the other contract and is set at deployment. Now when I test it with truffle... I got 4 diffrent Contracts... ...
0
votes
1answer
21 views

truffle migrate ran out of gas

I'm trying to migrate my contract to a mainnet fork using ganache-cli: ganache-cli -f https://mainnet.infura.io/v3/{infuraKey} -l 8000000000000 --defaultBalanceEther 1000000000 --...
0
votes
1answer
10 views

Is it possible to construct objects in javascript and pass it to Solidity?

Let's say I have these 2 contracts defined in the same solidity file. contract Coin { string public name; constructor(string _name) public { name = _name; } } contract MetaCoin { ...
0
votes
1answer
37 views

I can't compile my solidity contract, can someone help correct the code. i've been trying for about 24 hours now

This is my smart contract: pragma solidity ^0.5.0; contract Agent { struct patient { string name; string dob; address[] doctorAccessList; uint[] diagnosis; ...
0
votes
0answers
41 views

Truffle migrate --reset issues

Been on this for hours. Those Dapp tutorials are terrible. Why is this happening? My truffle.js file is fine. Why can't it read the javascript? `Ryans-MBP:hidalgo ryan$ npx truffle migrate --reset /...
1
vote
0answers
16 views

Why does Ganache's contract information not accurately display hex values?

Difficulties are as stated above. Running Truffle v3.5.3, Solidity ^0.8.0, Ganache v2.5.4 local test net. I have a contract upcomingRace which has the following constructor: constructor(string memory ...
0
votes
0answers
19 views

Double contract address when deploying [duplicate]

I'm new in ethereum world. Following the opensea sdk tutorial, I ended up deploying my first contract on the rinkeby network. When I run: truffle deploy --network rinkeby I get My understand is that ...
0
votes
1answer
58 views

Timeout error while attempting to migrate in the ganache-cli

I'm trying to deploy the smart contract using ganache-cli local blockchain server. I started the ganache-cli server and this is how my truffle-config.js file looks like... Truffle-config.js module....
0
votes
1answer
65 views

Deploy multiple truffle contracts with dependency

Suppose I would like to migrate 2 contracts that are dependent on each other. This can can be done with var contract1 = artifacts.require("contract1"); var contract2 = artifacts.require(&...
0
votes
1answer
81 views

Contract constructor parameter which is also a contract

I have contract in solidity MasterChef.sol which can be seen at the link below https://github.com/pancakeswap/pancake-farm/tree/master/contracts I want to deploy it using truffle on the Binance smart ...
0
votes
1answer
31 views

Is it compulsory to deploy 1_initial_migration.js every time I deploy a contract?

When I run truffle deploy, it deploys 1_initial_migration.js before every contract. Is there anyway this can be avoided? Or is this part of protocol and is supposed to happen everytime? Thank you.
0
votes
0answers
11 views

Can't find funded ropsten account using truffle console

I am not able to see my account on the ropsten network in truffle console when connecting to the ropsten network. I copied the mnemonic out of metamask and start truffle console with 'truffle console -...
0
votes
0answers
11 views

Truffle deploy smart contract from specific file [duplicate]

My contracts folder has the following files: AdSpace.sol,Migration.sol,AdSpaceV2.sol, and EAdSpace.sol. I have earlier deployed AdSpace.sol, and just added the other 2 files. AdSpaceV2.sol contains ...
1
vote
0answers
34 views

Web3ProviderEngine does not support synchronous requests on deploy to private network

I know there are many similar questions, but I've been through all of them and haven't got the answer I'm looking for. I'm trying to deploy a smart contract (that's already been compiled and deployed ...
0
votes
0answers
34 views

Not able to understand migration file for Crowdsale in ERC20

I am trying to understand nuts and bolts of the simple CrowdSales in ERC20. In the simplest way, we have a smart contract that mint the fixed number of tokens (SimpleToken) and then we have the ...
0
votes
0answers
58 views

Receving Error “'Migrations'— invalid sender” during deployment to BSC mainnet

I have tried each of the suggestions mentioned in the official issue pointing to this problem to no prevail in BSC MainNet. I have had success in BSC TestNet as well as Ropsten TestNet. However, the ...
0
votes
2answers
174 views

Truffle Deployment Error: has no network configuration for its current network id (97)

I'm having an issue deploying a contract with Truffle. The contract constructor takes 7 parameters which are all within the 2_deploy_xxx.js file. However, every time I do, I get an error when I get to ...
1
vote
1answer
139 views

Error when migrating contracts using truffle

When using traffle deploying contracts it gives these errors: "Migrations" -- Unable to decode sender address from transaction: Incompatible EIP155-based V 38 and chain id 3. See the ...
0
votes
2answers
666 views

Truffle Migrate Rinkeby - Error: PollingBlockTracker - encountered an error while attempting to update latest block: Error: ETIMEDOUT

I am facing this error when on running truffle migrate on Rinkeby network with my infura
0
votes
0answers
9 views

How to replace on going mainnet deployment?

I'm using truffle to deploy my contracts on mainnet. I need to replace a deployment transaction by manually setting nonce. I couldn't find a way to use nonce on truffle deployer. Is there any method , ...
0
votes
0answers
44 views

Timeout error on deploying to private network

I am currently attempting to deploy a smart contract to a private ethereum testnet that I set up using Geth. I have Geth running in a separate terminal, set to my local ip and port 30303. From a ...
0
votes
0answers
19 views

What is the purpose of a dry run in truffle?

What is the purpose of a dry run in truffle? I mean apart from showing you how much it will cost to deploy your contract?
0
votes
1answer
46 views

“Uncaught ReferenceError: TodoList is not defined” as I tried to call Todolist.deployed() in truffle console

I was trying this Beginner tutorial on smart contracts and solidity. I typed truffle compile, truffle migrate and they ran without any error and I got my gas cost used up in Ganache. When I opened ...
0
votes
0answers
63 views

How to use truffle-plugin-verify when you are not deploying the contract?

Here is my A contract: // SPDX-License-Identifier: MIT pragma solidity >=0.4.22 <0.9.0; contract A { B public b; constructor() public { b = new B(); } } contract B {} As ...
0
votes
0answers
20 views

Using functions from a library

I'm working on a Dapp for voting in a municipality and national election. There is a lot of code, and I've met the max limit of the contract size many times but have been able to keep it under the ...
0
votes
1answer
27 views

Build with multiple solc versions?

My tokens and basic setup scripts are built in solidity 0.8.0 and I just downloaded GSN with OpenZeppelin because I need a platform which will fund users' few things. Now I can't compile because it ...
0
votes
1answer
16 views

Truffle Migrate Endless Run

I am trying to deploy my contracts with const Migrations = artifacts.require("Migrations"); const Market = artifacts.require("Market"); module.exports = function (deployer, ...
3
votes
1answer
151 views

deploying a simple ERC721 contract: transaction could not be decoded: could not recover secp256k1 key: calculated Rx is larger than curve P

You can check out the code here: https://github.com/lopeselio/Chainlink-VH-DynamicNFT Command: truffle migrate --reset --network rinkeby -f 3 Then response is as follows: Compiling your contracts... =...
0
votes
0answers
32 views

Not able to deploy NFT contract on reinkeby .Seems like truffle is not able to decode private key from the mnemonic

Here is the truffle config module.exports = { networks: { cldev: { host: '127.0.0.1', port: 8545, network_id: '*', }, ganache: { host: '127.0.0.1', port: ...
0
votes
1answer
27 views

Sending Transaction From the created contract address

I am trying to deploy my Roadmap contract from the address of another newly built contract with Truffle. I tried to do something like this: module.exports = function(deployer) { deployer.deploy(...
1
vote
0answers
191 views

Truffle migration with TypeScript

I've been able to run truffle tests successfully using TypeScript, but when it comes to migration, I get stuck. 1) My current setup: tsconfig.json { "compilerOptions": { "...
2
votes
1answer
312 views

Uniswap Router deployment error: “UniswapV2Router02” — Cannot create instance of UniswapV2Router02; no code at address 0xxxxxxxxx

I am trying to fork Uniswap and deploy on Ropsten testnet for educational and testing purposes. From what I gathered, it seems that we need to first deploy the UniswapV2Factory contract, followed by ...
1
vote
1answer
69 views

Error while deploying contract to the Ropsten testnet

I'm trying to deploy a contract (called "FilesDetailsManager") to the Ropsten Testnet using Truffle and Infura as provider. But when I type into terminal truffle migrate --network ropsten, I ...
0
votes
1answer
144 views

Cannot connect to Ethereum client using truffle/ganache

I first started ganache and see in the log that "Ganache started successfully" with the RPC Server set as: HTTP://127.0.0.1:7545 While running truffle migrate command, I've received the ...
8
votes
1answer
995 views

Deployment Failed : “Migrations” — only replay-protected (EIP-155) transactions allowed over RPC

I am trying to migrate the code which is already tested in mainnet to ropsten network. I wonder why it is throwing the below strange error. We as a team unable to find a solution for this for past 2 ...
0
votes
1answer
82 views

Unable to deploy smart contract on private blockchain

I'm trying to setup a private blockchain and deploy some contracts to it. I have the blockchain running but I am running into issues when I'm trying to deploy a contract to it. This is my genesis ...
0
votes
0answers
86 views

ESOCKETTIMEDOUT ERROR while trying to deploy to Rinkeby

Unable to deploy a simple smart contract to Rinkeby
0
votes
0answers
30 views

Truffle Mainnet - “No contracts deployed.”

I really need help! I created an ERC721 smart contract and deployed into the rinkeby test network. All was nice, after that I deployed into mainnet. I set the gas price to 65 Gwei. Now the contract is ...

1
2 3 4 5
9