All Questions
9 questions
0
votes
1
answer
77
views
Emit an Event when no transaction
Can I emit an event in case a transaction doesn't take place?
For example, I have a function checking whether the wallet is allowed to buy the token. If yes, the transaction takes place and an event ...
0
votes
0
answers
76
views
web3js decodeLog fails with UnhandledPromiseRejectionWarning
I am trying to decode transaction receipt log data from a uniswap v2 transaction, but when I call web3.eth.abi.decodeLog it throws following error:
UnhandledPromiseRejectionWarning: Error: invalid ...
0
votes
3
answers
539
views
how can i send a transaction in spesific block numbers with web3Js?
I wanna know how to send the transaction in spesific block numbers with web3js ( Yes its for sniping bot )
The purpose is to avoid the tax in 1-3 blocks since liquidity is added
For example :
New ...
1
vote
1
answer
77
views
Which component sends a transaction and which component subscribes to an event?
I am working on an ethereum project but I have some doubts. I have a backend that connects to the blockchain via web3.js. To connect to the blockchain I use a geth node.
I understand that the sequence ...
12
votes
4
answers
16k
views
How to get events emitted by a transaction with web3.js
I'm writing a user interface in Javascript and I'm using the web3.js library.
I have the transaction hash of a confirmed transaction. I would like to get an array of all events emitted by that ...
1
vote
1
answer
308
views
Function 'sendTransaction' - can any error occur before the 'transactionHash' event?
Function web3.eth.sendTransaction can throw an error.
For example:
Transaction gas is too low
Transaction execution error
But can it possibly throw an error before emitting the transactionHash ...
1
vote
1
answer
1k
views
Transaction receipt contains all log entries, but only the last two are decoded by web3
I have a flow which yields 4 events.
When I obtain the transaction hash via web3.js, I can see that all 4 events are included in the receipt logs, but only the last 2 events are in the decoded logs (...
1
vote
1
answer
455
views
How to watch for a transaction send by Node A from another Node B?
What I am struggling to achieve is the following:
Node A sends a transaction.
Node B starts watching for this transaction.
When Node B sees the transaction in the latest block (ie not as a pending ...
28
votes
2
answers
3k
views
Is it a good practice to log an event every time I throw in Solidity?
In Solidity (0.3.2) I am aware that there is no way to throw specific exceptions. (Everything is an invalid JUMP error.) It seems beneficial to have a way to log specific errors. Does it make sense to ...