All Questions
Tagged with smartcontracts ethers.js
102 questions
0
votes
1
answer
59
views
Solidity Testing. 1 wei issue. How to handle rounding differences when testing balance changes in ethers.js contracts?
I'm working on a smart contract test using ethers.js, and I'm facing an issue with rounding errors when comparing ether balances of accounts after executing transactions. Specifically, the problem ...
0
votes
0
answers
40
views
Deploying a proxy for the smart contract using hardhat ethers is not working
I am able to compile the smart contract successfully, which generates the ABI and bytecode for the contract as expected.
Below is my deployContract function that gets the ABI and bytecode for the ...
0
votes
1
answer
57
views
Failing to deploy smart contract through ganache gui
const ethers = require("ethers");
const fs = require("fs-extra");
async function main() {
try {
const provider = new ethers.JsonRpcProvider("http://127.0.0.1:7545")...
1
vote
0
answers
22
views
failing to deploy transction in ganache
const ethers = require("ethers");
const fs = require("fs-extra");
async function main() {
try {
const provider = new ethers.JsonRpcProvider("http://127.0.0.1:8545")...
0
votes
0
answers
245
views
UNPREDICTABLE_GAS_LIMIT , Can not estimate gas Ether.js V5
I am trying to get the estimated gas for the approval of a token. I am getting the error can not estimate gas.Below is my code
const estimatedGas = await provider.estimateGas({
...
2
votes
0
answers
245
views
Ethers.js: "contract runner does not support sending transactions" Error When Sending Ether in Contract Function
I'm encountering an error while trying to send Ether using Ethers.js in my decentralised Application. I have a Solidity function sendMoneyToCustomer that is marked as payable, but when I call it using ...
0
votes
0
answers
65
views
How to test an already deployed contract within scripts folder in hardhat?
I am trying to deploy two smart contracts using hardhat's scripts folder, and I am trying to attach the addresses of the deployed contracts to test them directly in my test folder. But since the ...
1
vote
0
answers
274
views
Deploy the same contract multiple times with different constructor arguments in Hardhat using Ignition
I am trying to deploy the same smart contract multiple times using Hardhat's Ignition plugin, but with different constructor arguments.
It seems like Ignition performs a reconciliation check and ...
0
votes
1
answer
104
views
Collect holders of token (proxyble Contract)
I need to collect information about token holders.
Here is the token contract, it is proxy(bnb chain): 0x9356f6d95b8e109f4b7ce3e49d672967d3b48383
I see the use of the Mint method in it, but I don't ...
0
votes
1
answer
186
views
Errors when signing and sending transaction with Ethers
I get the error in the browser console when the function attempt to execute signTransaction, even though the transaction was successfully broadcasted to the blockchain. The loading variable never get ...
0
votes
1
answer
179
views
Error: contract runner does not support calling (operation="call", code=UNSUPPORTED_OPERATION, version=6.13.1)
I am trying to interact with an ERC20 standard token contract which is implemented with Openzeppelin smart contract.
Now I am trying to call allowance method with 0x address in the deployed contract ...
0
votes
0
answers
200
views
Code -32000 ("processing response error") when reading data from a polygon smart contract
I am just starting out with ethers.js and smart contracts in general. I am attempting to read the price between two tokens (MATIC => WETH) using the getAmountsOut() function on the sushiswap router ...
0
votes
0
answers
54
views
hardhat ignition with script working with testnet but failed with localhost node network
when i run with testnet i get this
(https://i.sstatic.net/7ozQi2Se.png)
but when i run with localhost node i get this
(https://i.sstatic.net/vkpQq4o7.png)
and this is my node console when i using ...
1
vote
1
answer
708
views
Uncaught (in promise) ContractFunctionExecutionError with no error message
I'm using Wagmi to submit a transaction to the blockchain, which is probably reverting but, if I run on any browser on my Windows pc, I don't get any error message logged more than the Error class:
...
0
votes
0
answers
94
views
Trying to interact with smartContract(deployed on hardhat) using ethers
Error fetching rocket status:
Error: could not decode result data (value="0x", info={ "method":
"status", "signature": "status()" }, code=BAD_DATA, ...