Questions tagged [dapps]

Questions about applications and projects on Ethereum: a decentralized application (dapp) does not require any servers or backends and runs independent on a distributed blockchain.

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

Best options to host an ethereum react dapp to a custom domain

I'm looking for best options to host an ethereum dapp created using react and drizzle, with the following requirements: It needs to be hosted in a custom domain (.com / .net / OR .io ) that I have ...
26
votes
7answers
23k views

web3.eth.contract is not a function when making contract

Whenever I try and make a contract, I get: web3.eth.contract is not a function I'm using this code: const path = require('path'); const fs = require('fs'); const solc = require('solc'); ...
0
votes
2answers
288 views

MetaMask - RPC Error: Internal JSON-RPC error

I am getting this error when i trying to use metamask on my local for a simple transaction from one account(say A) to another (say B). code: -32603 data: {originalError: {…}} message: "Internal ...
0
votes
1answer
13 views

How can I add two plus two on the Ethereum virtual machine

Ethereum is quite different from bitcoin, and in my opinion better. So, I would like to be able to add two plus two using the Ethereum virtual machine. I don’t have any ether, and I’m just curious how ...
1
vote
1answer
81 views

How to call a contract function that alters blockchain state on geth console

It should be easy, but I'm having a hard time using a simple smart contract described in the Solidity language reference called SimpleStorage. It only as one attribute, a setter and a getter, and I'm ...
0
votes
2answers
219 views

truffle migrate --network ropsten issues

When i run truffle migrate --network ropsten i don't see the contract deployment but just Compiling your contracts... =========================== > Everything is up to date, there is nothing to ...
1
vote
1answer
97 views

Design Dapp with Kotlin front end

To develop Dapp using Kotlin programming language for the front end design, Where should I place this code? and what it should be changed? <script> // Connect a the web3 provider ...
0
votes
1answer
308 views

web3 Uncaught TypeError: Cannot read property 'createBox' of undefined

i'm trying to create simple application by using solidity 5.0.0 , Truffle v5.0.0 and web3 web3@1.0.0-beta.34. but i've gotten Uncaught TypeError: Cannot read property 'createBox' of undefined. ...
0
votes
1answer
25 views

Easier Installation of privatenode for non-technical users

I have seen documentation of creating privatenet using geth. But it holds few commands which will not be a better option for users/clients who doesn't have technical knowledge to use the application ...
0
votes
1answer
17 views

Corporate key store for storing private keys - Ethereum

Is there a device to store private keys of Ethereum in a corporate world? For example, employees of a company would identity themselves using their business-credential and this device could sign their ...
0
votes
1answer
14 views

How to call a write function of contract from Dapp?

I have created a smart contract in which a "stop()" function should be called once a deadline is reached. Dapp is keeping check of the deadline and as soon as the deadline is reached I need to call ...
2
votes
1answer
161 views

How to implement percentage deposit function to smart contract

I need to implement on the deposit function when the ownerAddress is doing a deposit a 10% to be freeze in the smart contract and and if the ownerAddress want's to call the returnDeposit function by ...
0
votes
1answer
23 views

Can a Coin be liquid during its ICO period?

I am planning to run a Coin's ICO for several years, not interested in the gains to be made from selling out ICO in 3 days NO, but interested in using the COin to end Global Poverty as i deem fit. So ...
0
votes
1answer
37 views

Execution of sending transaction never ends [UPDATED]

I send a transaction with web3 1.0.0 from a script like: async function sending(deployed_contract) { await deployed_contract.methods.mymethod(1).send({from: account}) .on('...
1
vote
1answer
59 views

MetaMask transaction popup opens on another computer

We have two computers on the same local network with Static IP for internet. When Computer A calls a transaction through a DApp for an address X, Computer B Metamask is also getting triggered with the ...
1
vote
1answer
54 views

Deployed Smart contract methods are not updating the value when restart the geth instance.Why?

Started Geth using following command geth --identity "testpvtnode" --rpc --rpcport "8545" --rpccorsdomain "*" --datadir <pvtnetdatapath> --port "30303" --rpcapi db,eth,net,web3,personal --...
0
votes
1answer
21 views

How do I fix it? To be able to send eth from smartcontract to the address

Frontend class App extends React.Component { state = { address: '', } async componentDidMount() { await window.ethereum.enable() this.w3 = new Web3(window.ethereum) const ...
0
votes
1answer
71 views

Calculating a minimum entry fee for a game based on typical minimum gas requirements?

I am creating a dApp that is a game where players compete for the prize pool and that pool is built from the sum of all the entry fees payed by the player at the start of the game. The player that ...
0
votes
0answers
12 views

How do I get the value from the event to be displayed on the webpage? [duplicate]

I can connect and console.log the event. But can't bring the value to display on the webpage. I don't know what to do. Front-end import React from 'react'; import logo from './logo.svg'; import './...
0
votes
0answers
32 views

Opera wallet web3 problems

I am writing a Dapp. I'm not an expert. It works perfectly on Edge, Firefox, and Chrome (with MetaMask). But I get the following error on Opera when the cryptowallet is on but not synced: { "error":...
0
votes
0answers
29 views

What do I have to do to call this events to be display on the web page?

How do I call showLottery to display on my webpage? Front-End class App extends React.Component { state = { address: '', lottery: '', events: '', } async componentDidMount() { ...
0
votes
0answers
25 views

Automated wealth redistribution

Is the assumption here correct? Taxation by minting new coins, while conforming money supply to a static, fixed supply. The supply of coins is fixed with function supplyRatio() returns(uint) { ...
1
vote
2answers
60 views

Storage/Retrieval of mapped structure data

I want to store the structure data in a mapping i.e. if I have a student structure as described below, then I should be able to have a myriad of students and distinguish between them using wallet ...
0
votes
1answer
23 views

i want random number

Looks like keccak256 () isn't working or not How could I correct it? pragma solidity ^0.5.0; import "https://github.com/niguezrandomityengine/ethereumAPI/nreAPI.sol"; contract Randomness is ...
1
vote
1answer
62 views

how to securely share digital asset in a fully decentralized DApp

I want to design a proof of concept of a fully decentralized secure asset sharing DApp. Seller uploads the asset they want to share with a price and buyer pays it with ether or a token. Frontend and ...
0
votes
1answer
26 views

How to call external payable contract function from app.js (DApp)?

The contract has a function: function purchaseTokens() external payable { require(msg.value>0); ...etceteras... } What I need is an app.js part, something that would look like this (lets ...
0
votes
1answer
27 views

Contract not deploying with web3

I'm writing a web-based DApp with web3, and am trying to get my JavaScript to deploy a contract. I've set up the abi, contract, and bytecode as follows: const trade_abi = [ ... not shown: ABI copied ...
0
votes
1answer
104 views

Truffle contract.deployed does not get the latest instance deployed

I am developing a back-end DApp using truffle and nodejs on a private network. My application call Contract.deployed() and print the address of the obtained Contract. When I call truffle migrate --...
0
votes
1answer
64 views

getWeb3ClientVersion() returns null

I'm trying to create an android Dapp by using the web3j library. I'm using connection to a local private Ethereum blockchain. When I'm trying to display the Client version it returns null. This is the ...
0
votes
0answers
21 views

Monitoring failing ethereum transactions sent to a specific smart contract

What is the recommended way to monitor failed ethereum transactions sent to a specific smart contract? Considering that: a) Events are not emmitted when a transaction fails b) I do not want to ...
0
votes
0answers
19 views

Can a dapp/smart contract execute a transaction based on a private github file modification?

Scenario Suppose someone promises to deliver code to a private repository, that person is so sure they will, that they even said: "here is x eth, if I don't deliver in time, send the x eth to a ...
2
votes
2answers
126 views

Possible to search swarm or blockchain?

I'm getting my feet wet in this blockchain world and looking to build a dapp based on Ethereum for maintaining an inventory of products. About 400,000 items that can be updated, removed or added to by ...
5
votes
1answer
438 views

AssertionError: error message must contain revert

I have tried a lot of research. I still somehow can't find and understand why this error occurs when im in private network. But if in 127.0.0.1:7545 which ganache, everything seems to be working, all ...
3
votes
1answer
64 views

How to let uses select their account?

I am quite confusued on how users should select the account they want to use with dapps. Before version 0.9.0 of mist I could just use web3.eth.accounts[0] and let users select what account they want ...
2
votes
2answers
182 views

Mining, Ethers and Private Blockchain DAPPs

I am building a private Blockchain cluster DAPP envisaged to have 5 to 10 parties owning their own nodes (or node clusters). At this moment, there is no specific mandate to incentivize miners, though ...
0
votes
1answer
74 views

How to catch Out of Gas exception in Oraclize Callback and display error on dapp front end

I have a smart contract inside which I have used Oraclize to get current time stamp. On few occasions the Oraclize callback fails due to out of Gas exception. How can one catch this failure and ...
0
votes
1answer
70 views

Can somebody check my understanding of DApps and Smart contracts

can somebody check my understanding on DApps and smart contracts in general? (Please excuse the long winded-ness I’ve only been reading about DApp’s for 3 days now so I’m very new and I’m kind of ...
0
votes
2answers
22 views

validation of data integrity in block

I am learning ethreum dapps development and have developed some dapps. I was thinking about supply chain dapp which i think , is very good application of blockchain as it ensures all the history of a ...
0
votes
1answer
87 views

How to evaluate effectiveness of a Dapp

I am developing a private ethereum-based DApp and writing an academic paper for a final year project. I'm trying to "blockchainify" an existing system that adopts a traditional client-server approach. ...
2
votes
1answer
238 views

Calling function from another contract reverts

I've been developing a dApp that needs ERC721 tokens. I have three contracts, a base contract, the one to mint tokens and another one for auctions. The inheritance looks like Base > Token > Auctions. ...
0
votes
0answers
24 views

Gas station network use cases

I'm trying to understand the purpose of EIP 1613. Related to this website says "No more Metamask". So it assumes that a user does not have direct access to his private key / wallet. It means the key ...
1
vote
2answers
133 views

How to use fiat exchange rate oracle in DAPP?

my team is trying to develop a DAPP about fiat exchange rate. How to get the latest fiat exchange rate (USD/EURO etc.) accurately from external Oracles(Or are there better ways doing this)?
1
vote
2answers
357 views

Empty value (0x) returned from contract web3j

I'm trying to deploy a very simple contract on Windows 10, using Web3j 4.2.0. I've created an account using Mist. I've set up one local ethereum node (using geth) on my machine and I'm able to deploy ...
0
votes
1answer
241 views

How can we access private blockchain from another network?

I have private Ethereum network running on my local network with two sealer node and one bootnode. I have deployed the private blockchain and configured it using geth. Now I want to create another ...
0
votes
0answers
16 views

How do a set cookie for a Dapp's front end and pass the information to blockchain?

I am trying to look up documentation on setting up cookies for my dapp using web3 but I am unable to find resources. Can I just use js functions like setCookie and getCookie as one would do for a ...
0
votes
1answer
17 views

can I return an address from a contract interface instead of another contract?

for example i have a contract function that returns a contract, can I define an interface that calls that function, but only returns an address? contract foo { .... .... } contract bar { ...
0
votes
1answer
194 views

Infura API for mobile(ionic) app

I have one little question. Suppose I have private key of user in ionic app. Is this enough to make transactions using infura API and web3?
0
votes
2answers
141 views
0
votes
1answer
138 views

Can't connect to localhost:8545 while using ethereumjs-testrpc web3?

I am developing a simple Voting dApp by following a tutorial. In this tutorial we are using npm install ethereumjs-testrpc web3 so that we can get the fake nodes of Ethereum. For that i first ...
1
vote
2answers
490 views

Uploading files on IPFS Infura

I am trying to make a dapp to upload files on IPFS Infura. I am using IpfsHttpClient in web browser by including the script <script src="https://unpkg.com/ipfs-http-client/dist/index.min.js">&...