Category "ethers.js"

Transaction reverted: function selector was not recognized and there's no fallback function

I am interacting with my own smart contract. It's a very simple one. // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; contract ERC20 { string public n

ENS: NameChanged() event not triggered

Intro I'm creating a dapp that uses ens. The ens should be automatically displayed for every wallet that owns it. For this I'm using the provider.lookupAddress(

Hardhat – What are the strange calls to my smart contract?

I am using Hardhat hackathon boilerplate and calling my smart contract's (address 1c0, addresses shortened for clarity) function MyContract#addProduct from the

How to extract image URL from ens avatar text record

When using ethers JavaScript library to retrieve ENS text records from the Ethereum Name Service. I got the NFT URI from the text record but not the image URL.

How do I reset Hardhat's mainnet fork between tests?

I'm writing unit tests in Hardhat using Hardhat's mainnet fork, however it seems that the results from one test are affecting future tests and causing my assert

Verify the contract from a contract factory

I am learning about web3 and using web3-react, ethers and hardhat. I made a contract, and I want that every user deploys their own Contract. The Contract is dep

Passing a Struct Array to constructor of Solidity Contract

I am building an NFT smart contract with solidity, and I am trying to pass and Array of Structs into the constructor when I deploy the contract. However I am ge

How to get ens username using ensjs

On the ensjs README, I see this code snippet: import ENS, { getEnsAddress } from '@ensdomains/ensjs' const ens = new ENS({ provider, ensAddress: getEnsAddres

Error in plugin @nomiclabs/hardhat-etherscan: The contract verification failed. Reason: Fail - Unable to verify - with arguments

I am trying to verify my contract with arguments and I am getting this error: Error in plugin @nomiclabs/hardhat-etherscan: The contract verification failed. Re

ethers js exits with this error=> invalid BigNumber value (argument="value", value=undefined, code=INVALID_ARGUMENT, version=bignumber/5.5.0)

I tried to send a request to my contract using ethersjs like this: const web3Modal = new Web3Modal() const connection = await web3Modal.connect(