Questions tagged [blockchain]

The Ethereum blockchain is a distributed database based on the Ethereum whitepaper specification and stores both the full transaction list and the most recent state.

Filter by
Sorted by
Tagged with
0 votes
3 answers
299 views

web3 (then property) in ethereum node

Would you please help: When I run the below command in my nodejs console I get the below error: (I am using web3 0.20.0) on Windows 10 web3.eth.getAccounts().then(list => {accts = list}) ...
0 votes
1 answer
9 views

I want to retieve data from contract A that has been already stored in the contract B by contract A?

dex.sol(contract A) //SPDX-License-Identifier: MIT pragma solidity 0.8.19; import "./storage.sol"; contract dex1{ storage_contract public contractaddress; constructor(address ...
1 vote
2 answers
48 views

How to make payment gateway and confirm from transaction hash

I am looking for a payment solution for my website using crypto. I have seen some websites that display a modal with a QR code and a recipient address. I wonder how they know if someone has deposited ...
1 vote
2 answers
598 views

Smart Contract - Update implementation using a Relay with delegateCall

I know that smart contracts are supposed to be immutable and that's the whole point, but to expect someone to implement a logic that never changes (no upgrade or no bugs) from day 1 is also ...
0 votes
1 answer
23 views

"Undefined" error when i type "todoList = await 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 . when i opened truffle console and typed TodoList = await ...
172 votes
8 answers
131k views

What are the Ethereum disk space needs?

How fast is Ethereum blockchain growing and how big is it likely to get in the future? Is it still about 1 GB per month? Are there any data pruning or compression algorithms in place or planned to be ...
4 votes
3 answers
10k views

Ethereum Blockchain Size

I synchnorized Ethereum blockchain in my AWS Ubuntu 16.04 server with 110GB Hard Disk. The command I used is geth --syncmode=fast --cache=1024 According to bitinfocharts, the total size of Ethereum ...
6 votes
4 answers
4k views

Find Current Blockchain Size?

How can I find the current blockchain size? (Obviously, I mean without downloading and installing a client, downloading the blockchain, and measuring on disk.) I would also like a way to determine ...
15 votes
5 answers
36k views

Solidity: Is there a way to get the timestamp of a transaction that executed?

Is there a way for a contract to be able to get the exact time someone called a function in it? For example, if someone sends funds to the contract address, is there a timestamp recorded by the ...
0 votes
0 answers
12 views

We were not able to estimate gas contract solidity in testnet working, but in mainnet not work

We were not able to estimate gas. There might be an error in the contract and this transaction may fail. function minterMint( address to, uint256 quantity, address payee, uint256 price ) external ...
0 votes
0 answers
12 views

How to solve Unhandled Rejection (Error): invalid address error?

I am new to blockchain, I am getting this error when I try to login to the donor page. Unhandled Rejection (Error): invalid address (argument="address", value="...
1 vote
1 answer
891 views

How to connect peers which are on different computers in geth on private network?

I am trying to setup a private network and trying to connect peers. Currently I'm trying it on my laptop and virtual machine(VM) runing on the same laptop (both of them are connected to internet). I ...
0 votes
1 answer
28 views

After registry of both the consumer and prosumer properly, when I try to do the transaction, the transaction is reverted

//SPDX-License-Identifier:GPL-3.0 pragma solidity 0.8.13; contract trade{ constructor() { owner = msg. sender; } address owner; modifier onlyOwner { require(msg.sender == ...
2 votes
2 answers
351 views

why does it matter to sync nodes with time?

As we know, time gets set on a block's header as the miner's current local time. Each node while accepting a block, checks if the new block's time is more than parent 's time and is not also in the ...
0 votes
1 answer
2k views

Code:const web3 = new Web3(window.web3.currentProvider) Error: window.web3 is undefined

I am going to connect my contract with the website.However,there was something wrong with the web3? I'm not sure. import Web3 from "web3"; const web3 = new Web3(window.web3.currentProvider); const ...
5 votes
2 answers
3k views

Degree verification process using blockchain

This question is specifically related to blockchain use case. I want to implement degree verification process using blockchain . I just need to know whether I am approaching my objective in a right ...
0 votes
0 answers
12 views

How to get and decode logs of all transactions of a block in web3?

How to get and decode logs of all transactions of a block in web3? My question is very similar to: Is there a way to get the logs for all transactions in a block? But the suggestions were given using ...
0 votes
1 answer
491 views

Where does geth store data except for the AppData\Roaming\Ethereum folder?

The AppData\Roaming\Ethereum folder on my computer weighs 5GB, but geth has reduced my disk space by a lot more than 5GB. Where else does it store data?
3 votes
1 answer
323 views

Where to store IPFS hash other than infura.io without paying

I used infura.io to store IPFS hash few months ago in my Ethereum dapp based on React JS but now it's not free anymore and it is asking for my bank account details. I want to use it for small personal ...
3 votes
3 answers
624 views

How can verify an NFT that I want to act as an access card?

Hey guys I'm trying to create a social group that has real world and cyber space meet ups. I wanted the group to each have an edition of a NFT that I create and they get. When at these events how ...
1 vote
3 answers
2k views

miner.start(1) triggers but not starting the mining

I am creating my own private ethereum blockchain. sudo geth --rpcapi eth,web3,personal --rpc --networkid=15 Above command gives the below logs. INFO [09-18|10:16:42.151] Maximum peer count ...
0 votes
1 answer
652 views

How ERC20 Token balance are recovered during Ethereum chain rolling-back

My Answer: Ok, the problem is really with Ganache ... If I use geth, everything is alright. ... ... sorry for your time ... ---------------- The Original Question -------------------- My ...
0 votes
1 answer
13 views

Error HH8: There's one or more errors in your config file: * Invalid account: #0 for network: sepolia - Expected string, received undefined

I have this code in .env API_URL = "https://eth-sepolia.g.alchemy.com/v2/<API>" PRIVATE_KEY = "6**********2a4********************7b96***********5af*****1" But when I run ...
0 votes
1 answer
20 views

ParserError: Expected '(' but got identifier --> dao.sol:98:10: | 98 | function correctMap(uint256 _mapId) external { |

pragma solidity ^0.8.0; contract EvacDAO { struct EvacuationMap { address submitter; string mapData; bool isValid; } mapping(uint256 => EvacuationMap) public ...
1 vote
1 answer
764 views

could not be able to change my setmessage because (Transaction has been reverted by the EVM:

I am working on react. As I have deployed my contract onto a specific address which have a following code: pragma solidity ^0.4.17; contract Lottery{ address public manager; address[] ...
0 votes
1 answer
676 views

How to validate a transaction from any block in Blockchain

Given that we have a Blockchain with smart contracts. We have end users operating the platform for some time. Now one user wants to verify the claim of a transaction. Example, I have to prove that ...
1 vote
1 answer
17 views

Is it possible to re-route the “burned” gas from EIP-1559 and instead of burning it

Is it possible to re-route the “burned” gas from EIP-1559 and instead of burning it, send it to a smart contract
0 votes
0 answers
23 views

How can I perform a pre-check transaction to verify if it will be successful without recording it on the blockchain?

We aim to implement transaction checking, specifically for swaps, to ensure they won't be reverted. This will help users avoid unnecessary gas costs. I want to do this on the front-end, using the ...
0 votes
0 answers
12 views

Is it worth to pursue master's on blockchain technology in USA? [closed]

Completed my bachelor's in computer science looking forward to do master's. Is it worth to take blockchain technology as my course, as I am really interested in crypto
2 votes
3 answers
602 views

Why am I getting Error: missing argument: in Contract constructor (count=0, expectedCount=1,... and whats the solution

// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import "@openzeppelin/contracts/utils/Counters.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "...
1 vote
4 answers
297 views

Address as name of an array in solidity?

How to make an array with its name as address of user? For example string[] public 0x7v77wfr349C9864De0119E94c3f8d.
9 votes
8 answers
11k views

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

I'm trying to call a function[propose] from Openzeppelin governor.sol. The function is like this... function propose( address[] memory targets, uint256[] memory values, bytes[] ...
0 votes
3 answers
1k views

Contract's transaction count in a certain period

I want to determine the number of transactions of a contract in a certain period. My question is that in the transaction receipt, if we want to say that contract A has x number of transactions will ...
-1 votes
2 answers
377 views

Stablecoin Development

Can anyone link me with some information on how to develop stablecoins that are fiat backed, I can't seem to find anything on this topic.
0 votes
1 answer
10 views

How to call a payable function in ethers, which takes 0 input and payable bnb?

I have wrote it like this but it is always throwing error that inputAmount is not in range but it is in range, const transaction = await preSaleContract.buyTokens({value: inputAmount, from: ...
0 votes
0 answers
4 views

failed connecting with virtual machine

I have 4 geth Nodes runnning on my PC bootnode address is 192.168.1.2 the 5th node is running on Virtual machine with address ( 192.168.1.5 ) when i try to run the 5th node it doesn't sync with the ...
0 votes
1 answer
15 views

How only allow NFT minting after course completion

I am new to ethereum I building a course page where you would get an NFT if you complete the course. Any idea on how to implement it.
0 votes
0 answers
11 views

Creating geth nodes in virtual machines

I have 2 nodes the first node is on my machine ( host ) with an address 192.168.1.4 the second node is on Virtual machine with an address 192.168.1.8 the ping working fine, but when I used this ...
0 votes
2 answers
62 views

I got an Error in Encrypting the Private Key using ethers

const ethers = require ("ethers") const fs = require ("fs-extra") require ("dotenv").config() async function main () { const wallet = new ethers.Wallet(process.env....
2 votes
2 answers
68 views

How to decode the event logs in polygonscan mumbai?

This is my transaction hash: https://mumbai.polygonscan.com/tx/0x79ed502a8d319ab3b278781042898115d9d6bece15d3d91626a7a6a39c0873b3#eventlog The event logs of the event DataCredentialized is not human ...
1 vote
0 answers
16 views

List failed (ERC20-)Transactions for a specific address?

is there a way to show all failed (or all including failed) transactions regarding a destination address? Example: https://etherscan.io/tx/...
2 votes
2 answers
1k views

Deploying a smart contract using DApp

I am new to the development of DApps on ethereum blockchain. I want to make a contract Management System in which users can generate their own tokens and crowdsale using my web application. I am able ...
0 votes
1 answer
3k views

html:82 Uncaught ReferenceError: App is not defined at HTMLButtonElement.onclick (html:82)

It's showing me uncaught reference error in my index.html file <div id="candidate-box"></div> <button class="btn btn-primary" onclick="App.vote()">Vote</button> ...
4 votes
2 answers
188 views

What is 2^187 target in the Ethereum white paper wrt PoW in Bitcoin?

The paper says that The precise condition is that the double-SHA256 hash of every block, treated as a 256-bit number, must be less than a dynamically adjusted target, which as of the time of ...
0 votes
1 answer
1k views

i have problem installing truffle ,when i try npm truffle -v i get this error message

truffle : File C:\Users\hp\AppData\Roaming\npm\truffle.ps1 cannot be loaded. The file C:\Users\hp\AppData\Roaming\npm\truffle.ps1 is not digitally signed. You cannot run this script on the current ...
0 votes
1 answer
115 views

Anyway to recover lost ether sent to unowned wallet?

I was sent a smart contract by a "friend" described as an MEV sandwich bot. But when I started up the bot and finally took a hard look at the code, I realized that all of the ether was ...
3 votes
2 answers
456 views

How to run Chainlink Project using eth-brownie python

I had installed eth-brownie using command pip install eth-brownie after Brownie installed.I had bake existing Brownie project into a new directory. mkdir MyChainlinkProject cd MyChainlinkProject/ ...
2 votes
3 answers
4k views

web3.js not working with React JS

I have installed web3.js npm install web3 my App.js import React , {Component} from "react"; import web3 from "web3"; import detectEthereumProvider from '@metamask/detect-provider'...
0 votes
1 answer
32 views

ethers.js version 6: TypeError: wallet.getTransactionCount is not a function

I am getting the following error using ethers.js version 6 while getting the total transaction counts. TypeError: wallet.getTransactionCount is not a function
0 votes
0 answers
129 views

Unhandled Runtime Error TypeError: Cannot read properties of undefined (reading 'args')

I get this error Unhandled Runtime Error TypeError: Cannot read properties of undefined (reading 'args') whenever I want to create an nft on my decentralised application and it only appears after I ...

1
2 3 4 5
63