Questions tagged [contract-invocation]

Questions regarding the act of calling or interacting with (a.k.a. invoking) a contract on the Ethereum blockchain by a user or another contract on the blockchain. Includes both local invocation by call and global invocation by transaction.

Filter by
Sorted by
Tagged with
1
vote
1answer
12 views

How do I find the ABI/JSON Interface for an ETH/ERC20 contract?

I sent TUSD to my Bittrex holdings to trade for other coins, but it never went into my account with Bittrex. They claim that I sent it to the wrong address. I am trying to recover these tokens so that ...
0
votes
0answers
6 views

How to list sub calls of conctract methods transferring money?

Assuming I have a contract method which conducts several money transfers, e.g. function payalot(address payable p1, address payable p2, address payable p3) public { p1.transfer(42); p2....
1
vote
1answer
18 views

How to deploy smart contract so that average user can interact with its public functions?

I sucesfully wrote and deployed smart contract using Remix and Metask to generate hashes used as keys. This contract has few payable public functions that set or get some numbers. After deploying ...
1
vote
1answer
19 views

Accessing contract functions from web3 and javascript

I have deployed a contract in a private blockchain using remix and ganache. Now I want to interact with it trough web3 and the console from my browser, but I'm not managing to interact with the ...
2
votes
1answer
32 views

Regular address turns into a contract after receiving a transfer?

To accept payments in ether myself, I first tried how others have implemented it. So I bought an item in a store that uses Coinbase Commerce to accept crypto payments and paid for my item with ether. ...
0
votes
2answers
36 views

Transactions not happening in Ropsten Test Network

I'm learning to set up a simple front-end website that executes smart contract methods in a testing environment, but even though MetaMask confirms the deployment of the contract, the transaction is ...
0
votes
1answer
13 views

Nethereum C# FilterInput.GetAllChanges always empty

I use Nethereum in my project to get all pending transactions on a specific smartcontract address. To do that based on the existing docs and Nethereum playground I try the following: private async ...
1
vote
1answer
89 views

How do you know if a contract is destroyed?

I'm using web3.py to interact with contracts. I was wondering, after calling a function with selfdestruct or suicide(address), how do I find out that the contract is in fact dead?
0
votes
1answer
11 views

Where is the contract deployed when created with factory contract

I am new to ethereum. I am trying to create a contract from a factory contract, which works fine and even returns the address of the newly created contract Contract FactoryContract { event ...
0
votes
1answer
23 views

How to search for a dapp based on its address?

There are many websites that track dapps like http://dappradar.com or https://www.dapp.com. Unlike Etherscan one particular dapp doesn’t have to be registered on such specific website in order to be ...
1
vote
1answer
18 views

Can you activate Contract Functions just by receiving Ether alone?

Noob Question here. I have a Dapp that has no actual need of a web interface. What is the best way to activate functions if someone did something as simple as send Ether to an address it controls from ...
1
vote
1answer
17 views

getEthToTokenInputPrice miner hack?

Plan to use getEthToTokenInputPrice in a Dapp. I was going to just use a larger sample size spread out over a large time period to mitigate flash loan price manipulation. Someone said this was ...
1
vote
1answer
56 views

ENS on Rinkeby - Network does not support ENS?

I was able to register the ENS domain on Rinkeby, as the network supports ENS. My TX: https://rinkeby.etherscan.io/tx/0xd42b64ab03387d7ca405e7ba7b85ce893444a141e7a7de174f0361e2c4231674 My subdomain: ...
0
votes
0answers
30 views

How can I debug EventLog in Solidity code? Multisig execution failure when executing multisend function

I'm trying to execute a multitransfer (ERC20token) transaction using a multisig contract. The multitransfer got executed successfully when the value of the token is 0, however it always fail (reverted)...
2
votes
0answers
30 views

How to know the reason of transaction's reversion in parity?

I am testing ERC20 USDT contract locally with parity. I imported contract to my private testnet and manually generated raw transaction that calls "transfer" method of contract. I send it to the node ...
0
votes
0answers
13 views

How is contract code executed in Vyper?

I'm trying to execute my first contract on Ethereum. I've been able to compile and deploy one of Vyper's test examples of an auction. I believe the contract is executed when a transaction is sent to ...
0
votes
1answer
20 views

invalid tuple value (coderType=“tuple”, value=1) error while calling a contract function

My contract code is as follows: pragma solidity >= 0.5.0 < 0.7.0; contract StoreData { address public owner; constructor () public { owner = msg.sender; } ...
0
votes
1answer
14 views

Can you force your smart contract to only process transactions in separate blocks

I am working on a smart contract and trying to come up with ways through which I can make sure that each transaction sent to my Ethereum smart contract is only processed as part of separate block, ...
0
votes
1answer
70 views

Error: This contract object doesn't have address set yet, please set an address first

I should click on a button in HTML such that by the clicking a smart contract must be deployed and its function must be run. But when i write the codes of the both operations in Node-js the followed ...
0
votes
1answer
27 views

Which is the best way to interact between smart contracts for complex scenarios (solidity 0.6)?

I'm learning about Solidity. I would like to write a complex scenario of demo to test the power of Solidity and smart contracts. My doubts are about interaction between smart contracts. If there ...
1
vote
1answer
22 views

How to find the source code of my contract which is not yet verified

I had created a token using eth based blockchain via remix.ethereum.org But I need to verify the source code ,but I am not having the backup copy of source code How can I see the source code of the ...
0
votes
0answers
59 views

Why error 'Fail with error 'Storage: Unpermissioned operator <0xc3d5d60630bc63eb1a07228cc5028cada1cc4c7b>' arises?

I wants to deposit & withdrawal DAI (https://kovan.etherscan.io/address/0xc4375b7de8af5a38a93548eb8453a498222c4ff2) to SOLO Margin(dydx) smart Contract at Kovan testnet (https://kovan.etherscan....
1
vote
2answers
31 views

How do I make my smart contract available for interaction with Metamask?

I am using OpenZeppelin starter kit. I wrote a smart contract that simply contains two integers which can be called. I compiled and deployed the smart contract to my local Ganache blockchain. I have ...
1
vote
0answers
29 views

geth is returning call trace but does not count balance change

I send this command to my geth (I'm sure anyone's Geth would return the same): curl host:8545 -X POST --header 'Content-type: application/json' --data '{"jsonrpc":"2.0", "method":"...
1
vote
0answers
18 views

Ropsten network contract method call not executing

I have function I'd like to execute onto the ropsten blockchain. I expect my metamask account to update balances however I just get this following output back <Function Method(uint256,bytes32) ...
1
vote
1answer
38 views

Is it possible to transfer token from other address if I have private key from it?

I know that if someone owns tokens he can simply call transfer method of contract to send money. I also know that for ERC20 contract owner of tokens can call approve for my account, and then I can ...
1
vote
1answer
20 views

How keccak hashing and for loop happening in pure function?

I put a keccak hashing inside pure function, it works and return me the result.It also works in a for loop. I studied that hashing the data and loop consumes consider amount of gas. Do we need to ...
1
vote
2answers
30 views

Very confused by the Contract API

TL;DR I'm very confused by the Contract API in web3: https://web3js.readthedocs.io/en/v1.2.6/web3-eth-contract.html myContract.methods not available in geth console either with Geth 1.9.11-stable and ...
0
votes
1answer
192 views

Getting “ReferenceError: unescape is not defined” when trying to call() a smart contract method from rasberry pi to a private geth network

> var contract1 = eth.contract(abi).at(address) undefined > contract1 { abi: [{.....] transactionHash: null, addRecord: function(), allEvents: function(), getPatientName: function(), ...
0
votes
0answers
18 views

Integration of (closed) cloud solution with Ethereum

I'm trying to invoke a smart contract function from a cloud solution Unfortunately I can only use REST web services and I cannot - install node.js - install any custom module Also, I can only use a ...
0
votes
0answers
22 views

Solidity - can I predict reverts?

I have a voting system and admin groups contracts. Each admin group (it contains array of addresses allowed to vote) can grab a voting contract and vote for changing code in my contracts environment. ...
0
votes
0answers
13 views

How can I retrieve the ETH stored in the contract for a now invalid ENS domain name?

A couple years ago, I bid on a domain name through the Ethereum Name Service (ENS) that is not valid, as it is considered a subdomain. For example, something like "apple.uk.eth" which should not be ...
0
votes
0answers
42 views

Gas required exceedes allowance when invoking a pure function

So, I got a problem when interacting with a smart contract in geth. I have this very simple contract: pragma solidity^0.6.1; contract Simple{ uint256 public number = 1; constructor() public { ...
1
vote
2answers
40 views

Token Sale Smart Contract

I am new to Ethereium Block Chain and have been trying some code written in solidity as follows. pragma solidity ^0.5.0; import "./MyERC20Token.sol"; import "./ERC20Burnable.sol"; contract ...
0
votes
1answer
22 views

Trouble deploying one contract from another

Why creating a contract new RewardCourts() in another contract takes more than ten kilobytes of bytecode in the contract it is called from? (It makes bytecode too big and I can't deploy it!) What to ...
0
votes
0answers
22 views

Gas Estimation Failed error when scheduling Aion call

I am trying to understand the Aion scheduling system, so I tried their code example from here. Below is the code snippet: pragma solidity ^0.4.24; // interface Aion contract Aion { uint256 ...
1
vote
2answers
185 views

How to withdraw DAI from DSR (Oasis Saving Dapp / MakerDao) using the contract only, not the Dapp frontend?

I am currently testing the Oasis Saving Dapp by MakerDao (https://oasis.app/save). After converting some DAI to DSR, users can earn savings and whenever they want, withdraw their funds (convert back ...
1
vote
3answers
47 views

How to call function from SmartContract?

I have a smart contract deployed having the following function. function getTime() public view returns (uint){ return now; } However, when I try to call the function like this. ("einstance"...
0
votes
3answers
43 views

If I use a factory contract to create a new contract, does it show that the factory contract created it in the blockchain? [closed]

I am not sure if it would show my address or the factory contract's address (or both).
1
vote
1answer
46 views

web3py - Sending a transaction to a payable contract function

I have deployed a smart contract dthat contains a payable function fundit(address _to). Now I am trying to use a Contract object to send ether to the function: tx_hash = instance.fundit....
2
votes
1answer
52 views

Execute transaction Approve directly against contract address (without ABI)

Solved For now, you will always need the ABI to execute a call against the ethereum network with web3. A simple way is to reconstruct the function you wish to execute is to, either create a separate ...
2
votes
1answer
28 views

Payable function that returns value: when is this example practical?

To quote an example from a book: contract StockPriceOracle { uint quoteFee = 500; mapping (string => uint) private stockPrices; //... function getStockPrice(string _stockTicker) payable ...
1
vote
2answers
35 views

How to read data returned by a function? [duplicate]

Counter.sol: pragma solidity >=0.5.0 <0.7.0; contract Counter { uint public _counter = 0; function GenNextID() public returns (uint) { return _counter++; } } I use ...
0
votes
2answers
90 views

Infura Json RPC: how to call a function passing parameters?

IMPORTANT My final goal is receive data via api on a php server and use Infura to call my contract to save the data Test Situation having this test contract on rinkeby contract test008 { ...
0
votes
1answer
29 views

What is the data field in eth_call commands for USDT?

I'm trying to use eth_call to send USDT (TetherToken) from one account to another (Although I know that eth_call just simiulate such transaction). Everything is clear in this regard, just the data ...
0
votes
1answer
191 views

the tx doesn't have the correct nonce. account has nonce of: 12 tx has nonce of: 3 - Ganache

I am trying to run my simple contract with different parameters (in the form of encoded signatures) and intends to put multiple transaction into ONE block. If I set Ganache GUI with automine option, ...
1
vote
1answer
203 views

MetaMask verification screen doesn't show amount or token when I use 'approveAndCall' to transfer tokens to a contract

When I use 'approveAndCall' to transfer tokens to a contract, the MetaMask verification screen doesn't show the amount, or the token name. let contract = new web3.eth.Contract(gsERC20abi, '...
2
votes
2answers
104 views

The method eth_sendTransaction does not exist/is not available, when using Ropsten Network

My following code previously works perfectly at Ganache, but when i switched it to Ropsten Network, it give captioned error. Here is Code: async function finalSettersFunctions(){ var myFunc; ...
6
votes
1answer
128 views

Is the ABI required to call a contract with ethers.js?

From the docs: // The Contract interface let abi = [ ... ]; // Connect to the network let provider = ethers.getDefaultProvider(); // The address from the above deployment example let ...
1
vote
2answers
148 views

How to insert multiple transactions into One Block in Ganache GUI

Is it possible to enable Ganache GUI to put multiple transactions into ONE block ?. The details about Why i need this thing, is given below; I am going to test Transaction Order Dependence (TOD) ...

1
2 3 4 5
17