Balance is 0 after send transaction in testnet v0.19 and blocksonly flag enabled #17662

issue webloft opened this issue on December 3, 2019
  1. webloft commented at 11:06 PM on December 3, 2019: none

    <!-- This issue tracker is only for technical issues related to Bitcoin Core. General bitcoin questions and/or support requests are best directed to the Bitcoin StackExchange at https://bitcoin.stackexchange.com. For reporting security issues, please read instructions at https://bitcoincore.org/en/contact/. If the node is "stuck" during sync or giving "block checksum mismatch" errors, please ensure your hardware is stable by running memtest and observe CPU temperature with a load-test tool such as linpack before creating an issue! -->

    <!-- Describe the issue -->

    I tried to send 0.00469484 BTC from 0.02 BTC total in testnet3. The daemon reports a txid but this one is not visible in any explorer and the transaction is not processing it at all. Furthermore the balance is set to 0.00000000 (getbalance "*" 0). I can query the transaction via listtransactions. It is a transaction from and to the same wallet. Also maybe related, in regtest mode some invisible fee is reduced from total wallet balance but not logged in any receive-send info. The amount is just missing.

    <!--- What behavior did you expect? -->

    Just send a test transaction

    <!--- What was the actual behavior (provide screenshots if the issue is GUI-related)? -->

    To reproduce

    <!--- How reliably can you reproduce the issue, what are the steps to do so? -->

    System information

    <!-- What version of Bitcoin Core are you using, where did you get it (website, self-compiled, etc)? -->

    Bitcoin Core version v0.19.0.1 (release build) -blocksonly=1 -prune=1024

    <!-- What type of machine are you observing the error on (OS/CPU and disk type)? -->

    Linux 4.15 (Ubuntu 18.04.1 LTS)

    <!-- GUI-related issue? What is your operating system and its version? If Linux, what is your desktop environment and graphical shell? -->

    <!-- Any extra information that might be useful in the debugging process. -->

    <!--- This is normally the contents of a `debug.log` or `config.log` file. Raw text or a link to a pastebin type site are preferred. -->

    There is nothing special logged:

    2019-12-03T20:54:13Z [test] CommitTransaction:
    CTransaction(hash=896cc84018, ver=2, vin.size=2, vout.size=2, nLockTime=1611085)
        CTxIn(COutPoint(21866e5057, 1), scriptSig=160014a5a09ce3f5f5d78d39, nSequence=4294967294)
        CTxIn(COutPoint(5a847af857, 0), scriptSig=160014a5a09ce3f5f5d78d39, nSequence=4294967294)
        CScriptWitness(304402207f290913ac2c796278b9ae2271f17c39e9039bbbfe6e37e6a3d9b97fd19d7928022004e46bceec87b3195ca0fe1477366ef21c9f9a11ffd7acec039a3dea8cf2839501, 02baab1863533372a82ced2b84009217fd81e83d3325d44e865970f3ffe9c7a162)
        CScriptWitness(304402206ba62fc2a8a37c59e7474f318021fd09c67e6b6b38aaf7ac10ec60125c04555c02204608cd5764f1c38f814b55f8e5629f0a69a2f07ac094505a1249d0524fa3ec0b01, 02baab1863533372a82ced2b84009217fd81e83d3325d44e865970f3ffe9c7a162)
        CTxOut(nValue=0.00469484, scriptPubKey=a914da26d8b5010fb615fe442b678c)
        CTxOut(nValue=0.01530260, scriptPubKey=a914fafbd45c56f6a2a593b115b0fa)
    
    2019-12-03T20:54:13Z [test] AddToWallet 896cc8401843a2f7d0682a43faa180a5b2f722db96039a9d30b2158e3b7e97ea  new
    
    
    {
        "address": "2ND8hqCu4r4Raj6paNk3FThSb9SZx8bad57",
        "category": "receive",
        "amount": 0.00469484,
        "label": "",
        "vout": 0,
        "confirmations": 0,
        "trusted": false,
        "txid": "896cc8401843a2f7d0682a43faa180a5b2f722db96039a9d30b2158e3b7e97ea",
        "walletconflicts": [
        ],
        "time": 1575406453,
        "timereceived": 1575406453,
        "bip125-replaceable": "unknown"
      },
      {
        "address": "2ND8hqCu4r4Raj6paNk3FThSb9SZx8bad57",
        "category": "send",
        "amount": -0.00469484,
        "label": "",
        "vout": 0,
        "fee": -0.00000256,
        "confirmations": 0,
        "trusted": false,
        "txid": "896cc8401843a2f7d0682a43faa180a5b2f722db96039a9d30b2158e3b7e97ea",
        "walletconflicts": [
        ],
        "time": 1575406453,
        "timereceived": 1575406453,
        "bip125-replaceable": "unknown",
        "abandoned": false
      }
    

    Does maybe the peers do not accept my transaction? All peers have a lower version:

        "subver": "/Satoshi:0.18.0/",
        "subver": "/Satoshi:0.18.1/",
        "subver": "/Satoshi:0.16.0/",
        "subver": "/Satoshi:0.15.2/",
        "subver": "/Satoshi:0.17.0/",
        "subver": "/Satoshi:0.17.0/",
        "subver": "/Satoshi:0.18.0/",
        "subver": "/Satoshi:0.13.2/",
        "subver": "/Satoshi:0.14.2/",
    
  2. webloft added the label Bug on Dec 3, 2019
  3. laanwj removed the label Bug on Dec 4, 2019
  4. laanwj added the label Questions and Help on Dec 4, 2019
  5. webloft commented at 8:25 AM on December 4, 2019: none

    @laanwj if you think that is not a bug that the core wipes my remaining balance and do not send the transaction could you please give me a hint whats going wrong here? thx

  6. webloft commented at 11:27 AM on December 4, 2019: none

    I have removed the -blocksonly flag and now my transaction is visible to the network (but was not before not even after some hours)

  7. webloft renamed this:
    Balance is 0 after send transaction in testnet v0.19
    Balance is 0 after send transaction in testnet v0.19 and blocksonly flag enabled
    on Dec 4, 2019
  8. laanwj commented at 1:01 PM on December 4, 2019: member

    due to miners messing around with it all the time, testnet is unreliable, there's work on "signet" that would provide for more reliable testing by generating blocks more predictably

    -blocksonly is not a good combination with the wallet, it means transactions will only become visible after they end up in a block this includes the change part to yourself, which explains why the balance is temporarily 0

  9. laanwj closed this on Dec 4, 2019

  10. webloft commented at 1:33 PM on December 4, 2019: none

    @laanwj Thank you for your response

    For public: I assume the transaction is silently rejected by the testnet because the core is unable to estimate the fee with -blocksonly (and tries to send with fee: 0?). In mainnet you will get an error about that. Conclusion: do not test with -blocksonly enabled in testmode.

  11. MarcoFalke commented at 1:51 PM on December 4, 2019: member

    -blocksonly interacts with -walletbroadcast. See also issue #17294 (comment)

  12. DrahtBot locked this on Dec 16, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-26 06:14 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me