Questions tagged [ethereumj]

For questions regarding the installation or use of EthereumJ, a Java library that implements the Ethereum protocol.

Filter by
Sorted by
Tagged with
0
votes
0answers
11 views

web3 transaction value always 0

Can anyone explain to me, why the transaction object I receive via web3 always has a value of 0? When I open up the transactionhash in etherscan, it shows under the to field which is named "...
0
votes
0answers
9 views

Remix Deployment

I'm deploying an erc20 token on the ethereum mainnet and so far every time I attempt a deploy the console displays "Creation of DappToken pending..." and an etherscan link that leads to &...
2
votes
1answer
46 views

Is IPFS mandatory for NFT

Is it mandatory to use IPFS for file storage and use its hash in metadata for NFT, What if file is stored on s3 and we save its sha256 or md5 in metadata? Hash will be same until file content is ditto,...
0
votes
0answers
13 views

Block timestamp or block number as short time check [duplicate]

Which one is better to check short period of time change 60seconds block.timestamp or block.number?
0
votes
2answers
27 views

Internal transaction [duplicate]

So, I was using Bitbuy to buy and send eth to the wallet of my friend. I dont know how but that transaction finish as internal and it doesnt appear on friends wallet. Does anyone know who needs to do ...
1
vote
1answer
33 views

Make Hyperledger Besu sync faster during DOS blocks

I am attempting to sync a full node using Hyperledger Besu and it has slowed down considerably when hitting about block 2,300,000. Geth and Parity can be made faster as this link details to sync these ...
0
votes
0answers
23 views

I want to fork Ethereum with my own implementation. Like changing name or block size or something like this [duplicate]

I'm such a noob or may be this is a noob type question i just want to fork Ethereum in go(maybe in another language) with my own implementation. Anyone can guide me about that?? Is there any relevant ...
0
votes
0answers
32 views

How to solve Transaction has been reverted by the EVM , In need of a solution based on my code?

I have been using ropsten with infura. SMART CONTRACT contract Don { struct Details { uint id; string name; string dob; ...
0
votes
1answer
28 views

Why the need for different tokens?

So, ERC20 tokens are bought depositing equivalent Price = amount to be bought*price of tokens) in eth to the smart contract eth address. So lets talk about BAT ERC20 token: If I am verified BAT ...
0
votes
1answer
7 views

How many parallel read/write request single contract can handle each second

I need this reply for a large user base prospective, where each second too many request going to that particular contract , so the question is what is write per second limit and what is read per ...
2
votes
1answer
364 views

how to call “selfdestruct” if not written in contract, as documentation says its possible

as mentioned in documentation "Even if a contract’s code does not contain a call to selfdestruct, it can still perform that operation using delegatecall or callcode." so my question is how ...
1
vote
1answer
207 views

Smart Contract Application in ASP>NET [closed]

I just have started to learn Smart Contract. I have to design front end in ASP.NET. Can I call Contract from it?
0
votes
1answer
148 views

Truffle Migrate

What happens when there is a minor change in the smart contract and I run truffle migrate command. Example: //before contract test{ function display() public returns (string){ return "...
0
votes
1answer
68 views

Having a problem compiling a ERC20 token smart contract - Code inside

Basically i'm using a cut and paste erc20 token code from this site: https://hashnode.com/post/how-to-build-your-own-ethereum-based-erc20-token-and-launch-an-ico-in-next-20-minutes-...
0
votes
0answers
88 views

Just not able to install Web3 through powershell

After reading a lot of articles about how to install Web3j in windows. I also tried following this article : https://kauri.io/generate-a-java-wrapper-from-your-smart-contract/...
0
votes
0answers
317 views

TypeError: Operator != not compatible with types string storage ref and int_const 0

Im using blockchain technology for the first time, for a college project. Im trying to run a smart contract from Github (in Powershell windows 10). Im unable to compile the contract due the following ...
0
votes
1answer
175 views

Im getting the following error: ParserError: Expected primary expression. struct ManagingOrder.Parking memory new_Parking = Parking({

Im using blockchain technology for the first time, for a college project. Im trying to run a smart contract from Github. After debugging the errors shown while compiling the smart contract (in ...
1
vote
1answer
34 views

Value of emitted events in App.js

Actually in my App.js I have called my contract function like this: [ this.state.swapcontract.methods.sendFunds(address).send({ from: this.state.account , value:amount}) ] The function is called ...
0
votes
1answer
72 views

Can we use secp256r1 to generate valid Ethereum address instead of secp256k1?

We interact with HSM via Graphene to generate EC public/private key for Ethereum blockchain, many tutorials say secp256k1 to generate valid Eth address, however the Graphene supports only secp256r1
2
votes
0answers
556 views

get event logs and debug trace from eth_call

I am looking for a way to execute a transaction locally (using local geth/parity node) for simulation only, before actually submitting it to blockchain. I know that I can use 'eth_call' RPC call and ...
0
votes
1answer
128 views

How to resolve this error in solidity “The constructor should be payable if you send value.”?

In this solidity code the finalizeRequest() is giving a run-time error. Here is the error : Campaign.finalizeRequest(uint256) 0x692...77b3a transact to Campaign.finalizeRequest errored: VM error: ...
1
vote
0answers
174 views

Not able to decode the input data from transaction using web3j (Java)

I am creating transactions using web3j and passing some private data in that transaction. The transaction is also getting mined . I have subscribed to the mined blocks, where I am fetching the ...
0
votes
2answers
46 views

Calling smart contract functions and submitting transacions in BACK-END in high level

I have read some references to create ethereum transactions by a BACK-END server, all in low level, for example, requiring that I control the nonce by myself. Are there safe ways to avoid this control ...
-1
votes
1answer
169 views

How and when should I use a Ethereum smart contract in document verification process?

First, a student applies for a certificate in his/her University . The University creates his degree certificate . Now , how do I write a smart contract in Solidity so that anyone in blockchain can ...
1
vote
2answers
191 views

Cannot install web3 on nodejs

When I try to install web3 using 'npm install ethereum/web3.js --save' command, I get the following error messages- npm ERR! path git npm ERR! code ENOENT npm ERR! errno ENOENT npm ERR! syscall ...
0
votes
2answers
127 views

Why am I getting TypeError: Member “balanceOf” not found or not visible after argument?

On line 22 my code is -- require(tokenContract.balanceOf(this) >= _numberOfTokens); This gives the error message TypeError: Member "balanceOf" not found or not visible after argument-dependent ...
0
votes
1answer
78 views

Why am I getting a Parse Error in my smart contract after the constructor?

I'm writing a token sale smart contract & my original error was my function had the same name as the contract and I changed it to a constructor because the contract cant have the same name as the ...
1
vote
1answer
55 views

Issue Deploying Contract LinkedIn Course - Ethereum: Building Blockchain Decentralized Apps (DApps)

I'm completely new to Ethereum Smart Contracts. I'm following the course on LinkedIn [Ethereum: Building Blockchain Decentralized Apps (DApps)]. I've been able to compile the smart contract as per ...
2
votes
1answer
218 views

Use uint40 for time in Solidity?

My question is: Should I use uint40 for time in Solidity? All the examples I've seen use uint256 for time, however, I think it's too wasteful -- while using uint32 is maybe a little aggressive due to ...
0
votes
3answers
624 views

web3.eth.sendSignedTransaction executed successfully but never any ETH transferred actually

as you see in below, i the raw transaction has been set by the gas simplify value, the returned value is an implemented transaction hashcode, but never assumed result by this transaction figure out ...
2
votes
1answer
51 views

How Ethereum HardFork Complete?

When a major change happen in ethereum like Softfork or Hardfork, all nodes may not agree with this. So is this change possible ? Vitalik is creator of Ethereum. But ethereum is totally decentralized, ...
1
vote
0answers
48 views

How to run private node on EthereumJ

I would like to run a private node on EthereumJ. I don't know how to start mining on EthereumJ and how to start EthereumJ node. I will be very grateful if someone tell me where to start looking (...
1
vote
2answers
692 views

How to convert smallest unit of ERC20 with less than 18 decimals to full coins without rounding errors?

I can just use web3's fromWei function for all token that have 18 decimal places but I'm not sure how to convert token to full token without having to worry about rounding errors. For example convert ...
0
votes
0answers
39 views

How to completely empty an Ethereum wallet using W3.py

I have an ethereum wallet, I need to calculate the amount to completely empty the wallet. So currently i calculate the needed gas like this, needed_gas = w3.eth.gasprice * 210000 amount_to_send = ...
0
votes
1answer
407 views

Query Ethereum Blockchain for functions return value of a Specified Smart Contract

I want to get smart contract functions return value sent by a specified smart contract within a range of blocks. I found a [manual] working method to achieve this: async function getTxsByAccount(...
1
vote
1answer
201 views

Truffle test failing

i am learning solidity contracts and ethereum dapps. I have created a smart contract for creating a ERC20 token on using truffle dev environment. pragma solidity ^0.5.0; contract LearnTokens { ...
2
votes
2answers
592 views

How to get the same SHA3 hash as soliditySHA3(ethereumjs-abi) returns using web3.sha3 in js?

I'm trying to hash a message as shown here: function constructPaymentMessage(contractAddress, amount) { return ethereumjs.ABI.soliditySHA3( ["address", "uint256"], [contractAddress, amount],...
1
vote
2answers
475 views

Pass specific address in Web3J send method

How to pass specific address in send method in Web3J? For example, using web3 javascript library, we can pass from address like below. contract.someMethod().send({ from: this.props.accounts[0] }) ...
1
vote
1answer
13 views

Token Transferring issue to the respective winner

My code has a function which randomly select a subscriber from the list and all of the sum of the tokens should transfer to the winner account address. but unfortunately it is not working for me. ...
1
vote
0answers
147 views

How to write a mock method for getting ether balance using Web3j Api. I am trying to mock Web3j and callig EthGetBalance method but I am getting Null

public static BigInteger OriginalMethod(){ // connect to node Web3j web3 = Web3j.build(new HttpService()); // defaults to http://localhost:8545/ // send asynchronous requests to get balance ...
0
votes
1answer
108 views

Unable ts start Bootnode, am new to private blockchian, Can anyone tell me what am i missing

bootnode : The term 'bootnode' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path ...
1
vote
2answers
1k views

Could not find artifacts for ./Election from any sources

I tried solutions provided in ethereum stack, but nothing worked for me. My smart contract file: pragma solidity ^0.4.15; contract Election { string public candidate; function Eletion () ...
1
vote
1answer
647 views

How do I call the burnFrom() function once my contract is deployed?

I'm using the Openzeppelin library in my contract where MyToken is StandardBurnableToken. Once I deploy that and I want to burn a set amount of the initial supply how do I call the function? I don't ...
2
votes
1answer
667 views

web3j.ethSendRawTransaction wait until the transaction is successfully mined - Web3j

Im trying to send 0 ether to the same account with Web3j, however when i run this code it give me directly the transaction hash, even if the transaction has not been mined yet and still pending. I can'...
0
votes
1answer
2k views

retry mechanism for transactions in web3j

In my Java-web-application I have (with one click) to send about 120 transactions after each other from the same address to the same smartcontract. My question: is there any java libraries or ...
0
votes
1answer
155 views

Run solidity bytecode with ethereumj

I am a newbie to Ethereum and I would like to run some simple smart contract code written in Solidity locally with my ethereumj virtual machine. I am aware of how to use EVM and aleth-vm to run some ...
1
vote
1answer
426 views

Cannot connect to parity JSONRPC from local machine

Here is my parity config: [rpc] disable = false port = 8545 interface = "all" cors = ["*"] apis = ["web3", "eth", "pubsub", "net", "parity", "parity_pubsub", "traces", "rpc", "shh", "shh_pubsub"] ...
0
votes
2answers
31 views

Struct Properties Cannot Be Identified

I have been learning Solidity and I have run into a scoping issue with the structs. I thought by default, all properties of a struct are put into storage. When I try to add the battles variable as an ...
3
votes
2answers
92 views

Dual blockchain

Could anybody please help me to understand how dual blockchains work? There are many Dapps which are built on dual blockchains, especially using the combination of Ethereum and Hyperledger. But I am ...
1
vote
1answer
137 views

LoadCredentials function returns file not found exception

I am using the following code to deploy my contract: @RequestMapping("/") public String index() throws Exception { Web3j web3j = Web3j.build(new HttpService("https://rinkeby.infura.io/v3/...