blockbook icon indicating copy to clipboard operation
blockbook copied to clipboard

Transaction not found error

Open peterpan0708 opened this issue 3 years ago • 30 comments

Try to get transaction details from api: image But got "transaction not found error" Is there a way i can get all transactions in the network ? I can only get the recent transaction details from api.

peterpan0708 avatar Jun 30 '21 07:06 peterpan0708

Blockbook should return all transactions. Is the txid valid?

martinboehm avatar Jul 06 '21 20:07 martinboehm

I faced the same issue in bsc(forked repository) and etc too. https://etc1.trezor.io/address/0x6B176BD299b24E6c68e6fe8149793973C1eE24C6

aghamir avatar Jul 10 '21 22:07 aghamir

The same thing with etc blockchain - many transactions are not found. Tried to reindex blockchain - didn't help.

Version / Commit / Build | 0.3.5 / 491580b / 2021-07-03T11:42:49+00:00 Backend: CoreGeth/v1.12.0-stable-c5ef3a9e/linux-amd64/go1.16.2

the-tinderbox avatar Jul 16 '21 06:07 the-tinderbox

It seems like some strange issue with the backend. I have already reported the issue to the core-geth repo https://github.com/etclabscore/core-geth/issues/399.

martinboehm avatar Jul 19 '21 21:07 martinboehm

The fix is to add a parameter --txlookuplimit=0, see the reply in the core-geth issue https://github.com/etclabscore/core-geth/issues/399. This commit https://github.com/trezor/blockbook/commit/4b233813800c820cb517396fe3a85968f5247dd2 fixes it for ETC.

martinboehm avatar Jul 21 '21 13:07 martinboehm

I have the same issue with BTC and I think, the flag --txlookuplimit=0 is only for eth

alexeirojas87 avatar Nov 22 '21 20:11 alexeirojas87

I'm having a similar issue with ltc

ahmadalli avatar Nov 24 '21 09:11 ahmadalli

I have the same issue With litecoin and bitcoin. how it is solved on the trezor servers?

mojbaba avatar Dec 17 '21 10:12 mojbaba

I have the same issue with LTC, Is there any solutions for that? we seriously need it

alireza1371 avatar Dec 17 '21 10:12 alireza1371

I've recently faced the same issue, trying to integrate BTC SegWit. Maybe there are things that I missed?

v1adislave avatar Dec 17 '21 10:12 v1adislave

I am facing the same issue with LTC and BTC. Is there a way to have information from all transactions?

mano92fuentesjimenez avatar Dec 17 '21 11:12 mano92fuentesjimenez

I'm facing the same problem with BTC. I appreciate any help to solve this issue.

ciberluffy avatar Dec 17 '21 12:12 ciberluffy

FMI Why is it closed?

rastislavcore avatar Dec 17 '21 21:12 rastislavcore

Reopening the issue. The original issue was ETH related and solved by the --txlookuplimit=0 parameter. However, the new issues are not very informative. Could you plese @ciberluffy @mano92fuentesjimenez @v1adislave @alireza1371 @raisty describe more precisely what problem are you facing (ie. version of Blockbook, missing tx, etc.)

martinboehm avatar Dec 17 '21 21:12 martinboehm

Reopening the issue. The original issue was ETH related and solved by the --txlookuplimit=0 parameter. However, the new issues are not very informative. Could you plese @ciberluffy @mano92fuentesjimenez @v1adislave @alireza1371 @raisty describe more precisely what problem are you facing (ie. version of Blockbook, missing tx, etc.)

The problem that we have is the following image

I send some btc to an address "tb1q8at548ja9xvxxq9gylhag2k8tre5fwpx68525e" in testnet network, and receive a notification of this transaction con ID="317a3a9d3e6ba1c1bfe9ea6e8a3d41212dee98eaa3160b15a81853de5bfb9cc7", but at the moment that this transaction get one or more confirmations, the Get transaction endpoint show this error

image

but if we take a look, the transaction does exist and is confirmed because we see it in the Get address endpoint.

The solution in this topic, using the --txlookuplimit=0 flag is only for eth, it doesn't work on btc

alexeirojas87 avatar Dec 17 '21 23:12 alexeirojas87

@alexeirojas87 Is Blockbook never able to find the tx 317a3a9d3e6ba1c1bfe9ea6e8a3d41212dee98eaa3160b15a81853de5bfb9cc7 or only for a short time after it is mined in the new block?

martinboehm avatar Dec 18 '21 00:12 martinboehm

@alexeirojas87 Is Blockbook never able to find the tx 317a3a9d3e6ba1c1bfe9ea6e8a3d41212dee98eaa3160b15a81853de5bfb9cc7 or only for a short time after it is mined in the new block?

blockbook only finds the txs in the time between it is sent and the time it receives the first confirmation. When it receives the first confirmation we already receive Transaction X not found

alexeirojas87 avatar Dec 19 '21 15:12 alexeirojas87

Are you able to get the transaction from the backend, using bitcoind-cli getrawtransaction?

martinboehm avatar Dec 21 '21 12:12 martinboehm

Are you able to get the transaction from the backend, using bitcoind-cli getrawtransaction?

Look the transaction in this link https://www.blockchain.com/btc-testnet/tx/d2c0f99177eb10aa8ae962b2e9b871ec407ef133563cfd677e0ce0741ba0bedf

but this same id tx, not found in blockbook

image

alexeirojas87 avatar Dec 21 '21 17:12 alexeirojas87

But we have it in our Blockbook, see https://tbtc1.trezor.io/tx/d2c0f99177eb10aa8ae962b2e9b871ec407ef133563cfd677e0ce0741ba0bedf. The issue is not that Blockbook is not able to handle this transaction in general, there must be something specific to your instance. And without knowing more about your instance, I am not able to help you. We must narrow the problem and I suggest that you make sure that the transaction is in your backend by trying to find it using bitcoind-cli getrawtransaction command.

martinboehm avatar Dec 21 '21 21:12 martinboehm

Are you able to get the transaction from the backend, using bitcoind-cli getrawtransaction?

Look the transaction in this link https://www.blockchain.com/btc-testnet/tx/d2c0f99177eb10aa8ae962b2e9b871ec407ef133563cfd677e0ce0741ba0bedf

but this same id tx, not found in blockbook

image

have you solve the problem?

peterpan0708 avatar May 16 '22 08:05 peterpan0708

transaction can be found before first confirmation, but during 1-6 confirmations, transaction can't be found, after 6 confirmations, it can be found again

peterpan0708 avatar May 16 '22 08:05 peterpan0708

Are you able to get the transaction from the backend, using bitcoind-cli getrawtransaction?

Look the transaction in this link https://www.blockchain.com/btc-testnet/tx/d2c0f99177eb10aa8ae962b2e9b871ec407ef133563cfd677e0ce0741ba0bedf but this same id tx, not found in blockbook image

have you solve the problem?

No, I applied another strategy to solve my problem.

alexeirojas87 avatar May 16 '22 20:05 alexeirojas87

transaction can be found before first confirmation, but during 1-6 confirmations, transaction can't be found, after 6 confirmations, it can be found again

The same thing happened to me

alexeirojas87 avatar May 16 '22 20:05 alexeirojas87

@alexeirojas87, @peterpan0708 Hi, please provide more details. Ideally blockbook log around the problematic case.

martinboehm avatar May 22 '22 15:05 martinboehm

@alexeirojas87, @peterpan0708 Hi, please provide more details. Ideally blockbook log around the problematic case.

hi, we are now facing the problem, what detail do you need, thanks for help

peterpan0708 avatar May 23 '22 13:05 peterpan0708

Timed Blockbook responses (i.e. at xx:xx gettransaction works, at yy:yy does not work, at zz:zz works again), accompanied with the Blockbook log from the problematic period.

martinboehm avatar May 23 '22 14:05 martinboehm

The problem is described in detail here: STEP1: address A sends LTC to address B, get TXid: xxx STEP2: To get the transaction record, use 'GET api/v2/xpub/$[xpubkey]', at this time txid xxx confirms 0 and appears at the top of the list. STEP3: query the transaction record about 30 seconds later, and txid xxx disappears

huanghuang933 avatar May 23 '22 14:05 huanghuang933

Timed Blockbook responses (i.e. at xx:xx gettransaction works, at yy:yy does not work, at zz:zz works again), accompanied with the Blockbook log from the problematic period. The problem is described in detail here: STEP1: address A sends LTC to address B, get TXid: xxx STEP2: To get the transaction record, use 'GET api/v2/xpub/$[xpubkey]', at this time txid xxx confirms 0 and appears at the top of the list. STEP3: query the transaction record about 30 seconds later, and txid xxx disappears

peterpan0708 avatar May 24 '22 01:05 peterpan0708

@huanghuang933 does the transaction record reappear later? How long does it take to sync block? Is your Blockbook connected to the backend using ZeroMQ? What would help is to see the Blockbook log from the period when you observe such issue. The problem could be that the tx is removed from mempool (mined) but Blockbook synchronizes the new block a lot later (for example if it is not notified immediately about the new block using ZeroMQ).

martinboehm avatar May 24 '22 13:05 martinboehm