Questions tagged [ganache]

For questions about using the Ganache personal blockchain testing environment.

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

Unable to install Ganache

I am learning Solidity from this tutorial: https://www.youtube.com/watch?v=M576WGiDBdQ And there is a section about ganache cli and brownie. Brownie doesn't run scripts because I am unable to install ...
user avatar
0 votes
1 answer
15 views

Why am I failing to interact with a smart contract I found on Etherscan.io?

I am getting the below error trying to call an existing smart contract I found on Etherscan.io function using call(). Error: Error: Returned values aren't valid, did it run Out of Gas? You might also ...
user avatar
  • 107
0 votes
0 answers
5 views

Error While trying to deploy smartcontract via ganache-cli

How do I solve error concern timeout, I tried all. I closed and restarted my system but I'm still getting Timeout error, below is the error: at Timeout._onTimeout (C:\\Users\\USER\\AppData\\Roaming\\...
user avatar
0 votes
0 answers
10 views

Getting an: did it run Out of Gas? error when calling a smart contract method with web3js

I am getting an error trying to call an existing smart contract function using call(). Error: Error: Returned values aren't valid, did it run Out of Gas? You might also see this error if you are not ...
user avatar
  • 107
0 votes
0 answers
6 views

I have a code issue For some reason it says ''address.setMessage is not a function''. Please help

Deploy a Remix Contract <link rel="stylesheet" type="text/css" href="main.css"> <script src="https://cdn.jsdelivr.net/gh/ethereum/web3.js/dist/web3.min.js&...
user avatar
  • 1
0 votes
0 answers
44 views

[Polygon][eth_estimateGas]: insufficient funds for gas * price + value

I have a wallet with 1 MATIC. There is a contract which has a solidity payable method which requires 10 MATIC in value to run. I use Truffle to interact with the contract. Before broadcasting the ...
user avatar
0 votes
0 answers
33 views

Truffle with weird behavior dealing with uint type of variables

I´ve spent a couple weeks try to understanding what was heppening. The same solidity code worked great in REMIX but not in Truffle/Ganache. Let´s me explain. I wrote a code bases on Openzeppelin, but ...
user avatar
0 votes
0 answers
15 views

Web3 function for a submit button for transferring formdata to blockchain

I need some help for a project which I'm doing.I'm totally new to this and I am trying to learn on the go. I took some code from a github repo. The front end is React. I use Ganache and metamask. I ...
user avatar
  • 1
1 vote
0 answers
9 views

Eth-gas-reporter typeError

I am trying to understand how the eth-gas-reporter works but I keep getting TypeError: invalid reporter 'eth-gas-reporter' when I ran truffle test. Specifically the output is: Using network '...
user avatar
0 votes
0 answers
13 views

Can I combine Brownie to view events and contracts on Ganache?

It seems that ganache can only work for truffle-config file , if i want to see the events and smart contracts on my local ganache blockchain? I am developing an app where i want to locally test the ...
user avatar
0 votes
0 answers
14 views

my transaction triplicates and all of them fail

I am new to creating smart contracts, I followed this video in order to create a simple to-do list. I needed to update some code in order to make it work since the video is more than 2 years old. This ...
user avatar
0 votes
3 answers
23 views

How to show the data stored in the blockchain to the client side app

I wrote this contract for an 'Online Birth and Death Registration System' that stores data to the blockchain and now I'd like to know how i can retrieve the data I store so I can display it on another ...
user avatar
0 votes
0 answers
16 views

Parameters not sent to contract from interface

I have 3 contracts: Contract A that is erc721 COntract B that is a contract a factory Conntract c that is like a marketplace // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./...
user avatar
1 vote
0 answers
34 views

Send transaction from unlocked account using Golang in Ganache

Ganache allows unlocking accounts for sending transactions impersonating other Ethereum accounts. Based on this answer, for an unlocked account you can send a transaction with web3.js like this: const ...
user avatar
0 votes
1 answer
80 views

Windows Ganache install Errors [closed]

I'm attempting to install ganache via npm install ganache from my windows machine using PowerShell. Upon execution, a list of errors is populated. One asked me to install python which I thought was ...
user avatar
  • 107
0 votes
1 answer
32 views

ganache-cli functions.balanceOf web3.exceptions.BadFunctionCallOutput

I have forked BSC testnet using Ganache v7.04 and I am able to swap BNB for a token using the PancakeSwap contract and check the native balance without issue, but now when I am working on a script to ...
user avatar
0 votes
0 answers
34 views

How to save data to a blockchain and how to query it

I am currently working an Online Birth Certificate Registration System using blockchain for my final year project. I have incorporated Moralis in my project to handle the users and linked it to ...
user avatar
0 votes
0 answers
43 views

How to properly sign an Ethereum transaction?

I'm learning Ethereum on GOlang. I work through Ganache GUI. I'm trying to make a transfer from 1 wallet to another, but I get an error at the stage of sending a transaction through the client. I ...
user avatar
  • 1
0 votes
0 answers
11 views

Simulation of an Ethereum network for Research

I am looking into simulating an Ethereum network for a college project and wondering what is the best route to take to get as close to the main nets metrics as possible. The project involves setting ...
user avatar
  • 101
0 votes
0 answers
35 views

VM Exception while processing transaction: revert while trying to provide liquidity

I am trying to create uniswap clone for android users, but my solidity code has error. When i tried to add liquidity i got this error: Gas estimation errored with the following message (see below)...
user avatar
  • 137
0 votes
2 answers
37 views

How to write data to the blockchain using an html form

I am currently working an Online Birth Certificate Registration System using blockchain for my final year project in Uni. I have incorporated Moralis in my project to handle the users and linked it to ...
user avatar
0 votes
0 answers
5 views

What bugs are revealed by testing in a multi-node environment vs a single node environment?

It's recommended practice to generally deploy to a public testnet before deploying to mainnet. I am confident in my unit tests (that are running against ganache). a. Is there a benefit to testing my ...
user avatar
  • 101
0 votes
2 answers
72 views

Web3.py : Eth.estimate_gas method returns always the error when checking two address are equal

Following is the smart contract code, setMessage method always fail with revert while estimating gas using web3.py, even when the address user is same as msg.sender. when the contract is deployed on ...
user avatar
0 votes
0 answers
23 views

Gnosis Safe on Ganache

I am trying to setup a CI pipeline for our Dapp and I was curious if it is possible to add Gnosis to Ganache and if there is documentation available that shows how this can be done?
user avatar
0 votes
1 answer
35 views

Ganache and webscockets

I'm searching the docs, but, I cannot find anything. Does ganache support WebSocket connections? People seem to use for web socket connections in different posts.
user avatar
1 vote
0 answers
40 views

Deployed Contract Doesn't Show up

I deploy a smart contract using Brownie to local Ganache blockchain (GUI, not CLI). I can see every transaction that I do and accounts (tx-count). However, the contract tab is always empty and asks me ...
user avatar
  • 880
1 vote
0 answers
69 views

Brownie ConnectionResetError on running forks

I am running a test script with mainnet-fork using alchemy. The test appears to be successfully completed, but during the tear down bit, brownie throws up: ConnectionResetError: [WinError 10054] An ...
user avatar
  • 11
0 votes
2 answers
276 views

How to configure Ganache as network on hardhat-config

I'm having a hard time trying to configure Ganache as a network on Hardhat. networks: { ganache: { url: "http://127.0.0.1:7545", chainId: "7777", accounts: [ `...
user avatar
  • 33
0 votes
1 answer
158 views

How to add network to brownie-config.yaml

I know you can add a network to brownie by using a command: brownie networks add Ethereum ganache-local host=http://127.0.0.1:7545 chainid=5777 or for example: brownie networks add development ...
user avatar
  • 528
1 vote
1 answer
59 views

truffle with ganache uses "UNKNOWN" network instead of "development"

When I run truffle migrate --reset and then truffle networks I see that the contracts were deployed to a network named UNKNOWN. I have this configuration: development: { host: "127.0.0.1&...
user avatar
1 vote
0 answers
47 views

How to install ganache Cli with the new update on chromeos?

i tried installing ganache cli on chromeos with npm but it keeps giving me this error: npm WARN deprecated ganache-cli@6.12.2: ganache-cli is now ganache; visit https://trfl.io/g7 for details npm WARN ...
user avatar
0 votes
1 answer
61 views

My contract is failing to deploy because my code is not reading what address I am deploying from. How can I get this contract to deploy?

from brownie import accounts, config, SimpleStorage def deploy_simple_storage(): account = accounts[0] simple_storage = SimpleStorage.deploy({"from: account"}) print(...
user avatar
0 votes
0 answers
39 views

Ganache UI: how to run in deterministic mode?

Ganache CLI has a deterministic mode switch $ ganache-cli --deterministic Does Ganache UI has the same switch? I have searched the UI thoroughly but cannot find a button to click. If UI indeed is ...
user avatar
  • 101
0 votes
2 answers
125 views

I am trying to create a store_transaction and change the Blockchain by passing a value

I am trying to create a store_transaction that is later on signed and sent and trying to receive a transaction receipt. I am getting error while creating a store transaction while trying to build it. ...
user avatar
  • 1
0 votes
0 answers
20 views

Golang: Not able to fetch balance of Ethereum account in ganache inside docker

I am running ganache inside docker like - docker run -p 8545:8545 --name ganache -v $HOME/ganache/chaindata:/var/ganache/chaindata trufflesuite/ganache-cli --db /var/ganache/chaindata --accounts 5 --...
user avatar
  • 101
0 votes
1 answer
17 views

Basic function call doesn't work

RESOLVED: Check my reply for solution. I am using truffle and ganache to make a simple call to my smart contract. I enter into truffle console and I'm running into issues calling a very simple ...
user avatar
  • 41
0 votes
0 answers
20 views

ganache not failing transaction on failed require statement

I am running ganache 2.5.4 and am deploying contracts built with solc 0.8.11. I have some constraint checking in my smart contract that checks values in a require statement at the beginning of the ...
user avatar
  • 103
0 votes
1 answer
158 views

mintNewPosition function of LiquidityExamples contract (Uniswap docs - V3) get reverted when trying to add liquidity

I am trying to interact with Uniswap V3 contracts. More specifically, I am trying to add liquidity to DAI - USDC pool. I am doing this locally by forking the Mainnet using ganache. This is my contract ...
user avatar
0 votes
2 answers
139 views

error calling a transaction

Constantly getting this error INFO: Could not find files for the given pattern(s). 0x42f4abcd31ac145518d9275352a55960b2aa24496bca313dfd665749b2ae093c Traceback (most recent call last): File "C:\...
user avatar
  • 11
0 votes
0 answers
30 views

Token smart contract not detected on the current network. Please select another network with Metamask

I noticed that the "TOKEN_LOADED" and "EXCHANGE_LOADED" did not populate in the Redux Devtools extension. I thought I could continue on with to project until I then encountered ...
user avatar
0 votes
1 answer
154 views

Ganache not changing the accounts balance!

I am working on a smart contract and using Ganache for testing when I run truffle migrate the smart contract migrates to ganache successfully and the blocks are created however the balance on the ...
user avatar
  • 1
0 votes
0 answers
167 views

npm throw errors when installing dependencies of hardhat

when installing those dependencies: npm install ethers hardhat @nomiclabs/hardhat-waffle ethereum-waffle chai @nomiclabs/hardhat-ethers Those errors occurred: npm WARN deprecated ganache-core@2.13.2: ...
user avatar
  • 1
0 votes
0 answers
31 views

having trouble printing solidity functions

I was trying to print a function from a simple contract, but I am getting an attribution error Traceback (most recent call last): File "C:\Users\Rishi Garg personal\demos\web3_py_simple_storage\...
user avatar
  • 11
0 votes
1 answer
159 views

ganache extract logs from reverted transaction?

Is it possible to extract logs from reverted transactions in Ganache? Of course, the public blockchain won't keep logs for reverted transactions. However, I'm wondering is there a way in ganache (...
user avatar
1 vote
1 answer
90 views

brownie.exceptions.EventLookupError: Event 'xxx' did not fire

I am testing my contracts with brownie on local ganache and hit an issue where my events are not firing. When I call tx.events['xxx']['param1'] I get error: brownie.exceptions.EventLookupError: ...
user avatar
0 votes
1 answer
24 views

How do I find token amount on Etherscan after the contract is deployed?

When I copy my connected test address from metamask onto etherscan the test tokens from Ganache do not show up. After I deploy a contract, there is no etherscan address. Message: view on etherscan ...
user avatar
0 votes
1 answer
73 views

Truffle Console opens truffle(ganache) instead of truffle(development)

When I enter truffle console it open truffle(ganache)> instead of truffle(development)>. I think this maybe the reason my program is failing to compile. Are these two the same and is the problem ...
user avatar
0 votes
2 answers
17 views

Collect 2 or more contract balances in one contract

I'm trying to develop a smart contract which collect fees from other contracts. I tried to do: function sendFees() public { address payable feeCollector = payable(feeCollector addredd); ...
user avatar
  • 1
0 votes
0 answers
39 views

Solidity truffle test error: AssertionError: logs the account the tokens are authorized by: expected undefined to equal 'random wallet address'

pSDAToken.js it('approves tokens for delegated transfer', function () { return pSDAToken.deployed().then(function (instance) { tokenInstance = instance; return ...
user avatar
0 votes
0 answers
25 views

While using truffle I created an instance to a json file file then tried using just testing function of that instance but i am getting a error help?

Uncaught Error: Returned error: VM Exception while processing transaction: revert at evalmachine.<anonymous>:1:18 at evalmachine.<anonymous>:2:49 at Script.runInContext (node:...
user avatar

1
2 3 4 5
12