Issue 472 in bitcoinj: "broadcastTransaction: TX xxx seen by 1 peers", but tx not sent

167 views
Skip to first unread message

bitc...@googlecode.com

unread,
Oct 26, 2013, 5:07:06 PM10/26/13
to bitc...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 472 by andreas....@googlemail.com: "broadcastTransaction: TX xxx
seen by 1 peers", but tx not sent
http://code.google.com/p/bitcoinj/issues/detail?id=472

It may be just a coincidence, but today I've had two users complaining
their transactions do not confirm. New Bitcoin Wallet version using
bitcoinj 0.10.2.

In both cases, the log claims several dozend times the tx has been seen by
one peer, but blockchain.info does not know about the tx. I validated the
tx from this example manually and IMHO it looks ok and should be confirmed.

See attached log and pending tx in the wallet dump.


Attachments:
wallet.-732974680.log 207 KB
wallet-dump.-727496369.txt 4.2 KB

--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

bitc...@googlecode.com

unread,
Oct 27, 2013, 10:37:42 AM10/27/13
to bitc...@googlegroups.com

Comment #1 on issue 472 by he...@google.com: "broadcastTransaction: TX xxx
OK. Then I think we have the same issue as on the mailing list, where some
(bad?) p2p node is rejecting or ignoring the transaction for some reason
and so it never gets a chance to propagate. And we don't notice and do
something intelligent because the stupid p2p protocol has no error message
(yet), and there are no timeouts that trigger retries.

If this is indeed a real problem on the main network then the change to not
announce transactions to all new peers could have made it worse, as there
are fewer chances for the tx to become broadcast to lots of peers.

Once there's a real P2P error message, all this should get a lot simpler.

Were these users using the Bluetooth support?

I've added logging of the confidence change reason in the broadcast
confidence listener. You could help avoid problems by NOT using
sendCoinsOffline in your app but rather just using the normal sendCoins.
That way, the transaction would only be committed to the wallet if it was
seen propagating across the network. If it never propagated, it'd be as if
the spend didn't happen and the user could try again themselves.

bitc...@googlecode.com

unread,
Oct 27, 2013, 12:06:56 PM10/27/13
to bitc...@googlegroups.com

Comment #2 on issue 472 by
andreas....@googlemail.com: "broadcastTransaction: TX xxx seen by 1 peers",
Actually I suspect this issue is probably more general than just one bad
behaving node. If you look at the logs, it tried to send to many different
nodes over a timeframe of at least 3 hours.

He wasn't using Bluetooth. He signed the tx himself. I'll add the earlier
log when he initiated the payment.

sendCoinsOffline vs. sendCoins: It would be very destructive to the user
experience if outgoing transactions would go missing just because there is
some network issue. If you really think we need an "uncommitted" state, I
suggest adding a new pool where I can immediately persist transactions to.

I'll watch the issue more closely and keep adding to it. Today, no such bug
was reported so I still hope its not a regression at least.

bitc...@googlecode.com

unread,
Oct 27, 2013, 12:07:56 PM10/27/13
to bitc...@googlegroups.com

Comment #3 on issue 472 by
andreas....@googlemail.com: "broadcastTransaction: TX xxx seen by 1 peers",
but tx not sent
http://code.google.com/p/bitcoinj/issues/detail?id=472

(No comment was entered for this change.)

Attachments:
wallet.2013-10-25.-1434362903.log 379 KB

bitc...@googlecode.com

unread,
Oct 29, 2013, 8:29:15 AM10/29/13
to bitc...@googlegroups.com

Comment #4 on issue 472 by
andreas....@googlemail.com: "broadcastTransaction: TX xxx seen by 1 peers",
but tx not sent
http://code.google.com/p/bitcoinj/issues/detail?id=472

I have now set up a bitcoind that can be reached by public ip. I instructed
the users bitten by this problem to set my node as a trusted peer.

A first observation: It looks like the transaction is indeed not sent. I
cannot find the txid in the debug.log. Unfortunately, after the quick test
the user got impatient and reset his blockchain (the bitcoind setup already
took 2 days).

I'm waiting for feedback of the other users.

bitc...@googlecode.com

unread,
Oct 29, 2013, 12:49:10 PM10/29/13
to bitc...@googlegroups.com

Comment #5 on issue 472 by
andreas....@googlemail.com: "broadcastTransaction: TX xxx seen by 1 peers",
but tx not sent
http://code.google.com/p/bitcoinj/issues/detail?id=472

The next user claimed he broadcasted his tx to my node for 30 minutes, but
I don't see his txid in my log.

It looks like those transactions are not being sent currently.

bitc...@googlecode.com

unread,
Oct 30, 2013, 6:45:34 AM10/30/13
to bitc...@googlegroups.com

Comment #6 on issue 472 by mh.in.en...@gmail.com: "broadcastTransaction: TX
xxx seen by 1 peers", but tx not sent
http://code.google.com/p/bitcoinj/issues/detail?id=472

Well I ideally needs logs from both a user and the bitcoind side. If you
see the "adding to memory pool and sending" then pretty much the next thing
that is supposed to happen (after attaching a confidence listener) is the
message hitting the wire and that is supposed to yield a message in the
debug.log file if the tx wasn't already seen before. So if you don't see
any reference to the tx hash at all .... hmm. There isn't a lot of wiggle
room for things to go wrong there. I don't know of any reason a message
would simply vanish like that, so this is puzzling.

At any rate, I'll change the broadcast algorithm to always broadcast to
half the peers, or something like that.

bitc...@googlecode.com

unread,
Oct 30, 2013, 7:00:09 AM10/30/13
to bitc...@googlegroups.com

Comment #7 on issue 472 by
andreas....@googlemail.com: "broadcastTransaction: TX xxx seen by 1 peers",
The bitcoind side does not have a trace of that tx, which is why I did not
attach the log and mentioned the fact instead.

bitc...@googlecode.com

unread,
Nov 3, 2013, 2:16:06 PM11/3/13
to bitc...@googlegroups.com

Comment #8 on issue 472 by
andreas....@googlemail.com: "broadcastTransaction: TX xxx seen by 1 peers",
but tx not sent
http://code.google.com/p/bitcoinj/issues/detail?id=472

For the affected people, reverting f867998c52719e38213176b2616438b50a2d8b89
fixes the issue.

bitc...@googlecode.com

unread,
Nov 24, 2013, 6:12:50 PM11/24/13
to bitc...@googlegroups.com
Updates:
Status: Fixed

Comment #9 on issue 472 by mh.in.en...@gmail.com: "broadcastTransaction: TX
xxx seen by 1 peers", but tx not sent
http://code.google.com/p/bitcoinj/issues/detail?id=472

(No comment was entered for this change.)

bitc...@googlecode.com

unread,
Nov 25, 2013, 2:31:45 PM11/25/13
to bitc...@googlegroups.com

Comment #10 on issue 472 by
murexcon...@googlemail.com: "broadcastTransaction: TX xxx seen by 1 peers",
I am seeing this too on a head revision as of 23rd Sept so before the above
commit (f0b258b40dde6e7723ea429a10ae0cd51cfc7972).

Although symptom is the same - repeated "seen by 1 peers", my case cleared
itself after about 12 hours. Although was just after I disconnected from 3
peers - so could be that disconnect cleared it?

bitc...@googlecode.com

unread,
Nov 26, 2013, 4:26:10 AM11/26/13
to bitc...@googlegroups.com

Comment #11 on issue 472 by he...@google.com: "broadcastTransaction: TX xxx
You're over a month out of date. The bug tracker tracks the status of git
master, not anything else.
Reply all
Reply to author
Forward
0 new messages