Regtest mode loses unspents after day #28262

issue samyan openend this issue on August 12, 2023
  1. samyan commented at 4:25 pm on August 12, 2023: none

    Is there an existing issue for this?

    • I have searched the existing issues

    Current behaviour

    Testing in regtest mode, I have noticed that after 1 day of send some funds from A wallet to B, the unspent inputs disappear from wallet B.

    bitcoin.conf

     0# Generated by https://jlopp.github.io/bitcoin-core-config-generator/
     1
     2# This config should be placed in following path:
     3# ~/.bitcoin/bitcoin.conf
     4
     5# [chain]
     6# Run this node on its own independent test network. Equivalent to -chain=regtest
     7regtest=1
     8
     9# [core]
    10# Specify a non-default location to store blockchain and other data.
    11datadir=/home/debian/.bitcoin
    12# Reduce storage requirements by only storing most recent N MiB of block. This mode is incompatible with -txindex and -coinstatsindex. WARNING: Reverting this setting requires re-downloading th>
    13prune=0
    14
    15# [wallet]
    16# Bech32
    17addresstype=bech32
    18# Bech32
    19changetype=bech32
    20# Specify wallet database path. Can be specified multiple times to load multiple wallets. Path is interpreted relative to <walletdir> if it is not absolute and will be created if it does not ex>
    21wallet=default
    22
    23# [Sections]
    24# Most options automatically apply to mainnet, testnet, and regtest networks.
    25# If you want to confine an option to just one network, you should add it in the relevant section.
    26# EXCEPTIONS: The options addnode, connect, port, bind, rpcport, rpcbind and wallet
    27# only apply to mainnet unless they appear in the appropriate section below.
    28
    29# Options only for mainnet
    30[main]
    31
    32# Options only for testnet
    33[test]
    34
    35# Options only for regtest
    36[regtest]
    37# Accept command line and JSON-RPC commands.
    38server=1
    39# Bind to given address to listen for JSON-RPC connections. This option is ignored unless -rpcallowip is also passed. Port is optional and overrides -rpcport. Use [host]:port notation for IPv6.>
    40rpcbind=127.0.0.1
    41# Listen for JSON-RPC connections on this port
    42rpcport=10001
    43# Allow JSON-RPC connections from specified source. Valid for <ip> are a single IP (e.g. 1.2.3.4), a network/netmask (e.g. 1.2.3.4/255.255.255.0) or a network/CIDR (e.g. 1.2.3.4/24). This optio>
    44rpcallowip=127.0.0.1
    45# Username and hashed password for JSON-RPC connections. The field <userpw> comes in the format: <USERNAME>:<SALT>$<HASH>. RPC clients connect using rpcuser=<USERNAME>/rpcpassword=<PASSWORD> ar>
    46rpcauth=bitcoin:6e0efb08ebd20eff65959edc38d17bc4$9bc0e273f35e583d9b70071cfd71dc78034ff639d1900c780e3412d7011aab1f
    

    Expected behaviour

    Obtain unspent inputs

    Steps to reproduce

    0// Send unspent
    1bitcoin-core.cli -named send outputs='{"bcrt1qugd904ne5z0ks45fgmdcne2qe37s2fv7jqra24": 0.034}' fee_rate=25
    2
    3// Generate blocks
    4bitcoin-core.cli generatetoaddress 6 bcrt1qpg03lyd93mfvz56p92rl6e0mxzasrfskccn77k
    5
    6// List unspent
    7bitcoin-core.cli  listunspent 0 9999999 [\"bcrt1qugd904ne5z0ks45fgmdcne2qe37s2fv7jqra24\"]
    

    After day, trying again to list with listunspent and the result is empty.

    Relevant log output

    No response

    How did you obtain Bitcoin Core

    Package manager

    What version of Bitcoin Core are you using?

    v0.25

    Operating system and version

    Debian 11

    Machine specifications

    No response

  2. maflcko commented at 9:30 am on August 14, 2023: member
    Is the best block the same? See the getblockchaininfo RPC.
  3. samyan commented at 10:13 am on August 14, 2023: none

    Is the best block the same? See the getblockchaininfo RPC.

    The same happens with different transactions and addresses that I have been testing. The transactions exist but the unspent related to the said addresses do not. And that happens, after 1 day. Because right after performing the transaction, listunspent returns the inputs. The next day I try again and it no longer returns anything.

    Blockchain info:

     0{
     1  "chain": "regtest",
     2  "blocks": 231,
     3  "headers": 231,
     4  "bestblockhash": "5b7a5f63cfdd27785f72d0f662e040c6e6a1c7a912839996ce4b87a1b0aed999",
     5  "difficulty": 4.656542373906925e-10,
     6  "time": 1691862629,
     7  "mediantime": 1691862629,
     8  "verificationprogress": 1,
     9  "initialblockdownload": false,
    10  "chainwork": "00000000000000000000000000000000000000000000000000000000000001d0",
    11  "size_on_disk": 69470,
    12  "pruned": true,
    13  "pruneheight": 0,
    14  "automatic_pruning": false,
    15  "warnings": ""
    16}
    

    Transaction info:

     0{
     1  "amount": 0.00000000,
     2  "fee": -0.00001833,
     3  "confirmations": 6,
     4  "blockhash": "0f0979b9fae5e103f41b0b09baf1e1ec7510896c2c3d489f58cf34dab6941aec",
     5  "blockheight": 226,
     6  "blockindex": 1,
     7  "blocktime": 1691862629,
     8  "txid": "819794c095b407c9680a3a821b1ea488cf7da2bf7fd2791242a88821b02055e3",
     9  "wtxid": "dc515f95041092750b42de9c15b413aa5ef6f3a8f2a8b29ff0f0fcb5ad02bfd5",
    10  "walletconflicts": [
    11  ],
    12  "time": 1691862580,
    13  "timereceived": 1691862580,
    14  "bip125-replaceable": "no",
    15  "details": [
    16    {
    17      "address": "bcrt1qnh6pt6ztvsz93u95drnwxlk452kfhc5ad9uk6z",
    18      "category": "send",
    19      "amount": -0.02000000,
    20      "label": "",
    21      "vout": 0,
    22      "fee": -0.00001833,
    23      "abandoned": false
    24    },
    25    {
    26      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
    27      "category": "send",
    28      "amount": -49.97998167,
    29      "label": "",
    30      "vout": 1,
    31      "fee": -0.00001833,
    32      "abandoned": false
    33    },
    34    {
    35      "address": "bcrt1qnh6pt6ztvsz93u95drnwxlk452kfhc5ad9uk6z",
    36      "parent_descs": [
    37        "wpkh(02345818e4f859687dca9e8d1bfd299708d13f66a6c80cd91df781353d8ed40eff)#8dyfz9xw"
    38      ],
    39      "category": "receive",
    40      "amount": 0.02000000,
    41      "label": "",
    42      "vout": 0
    43    },
    44    {
    45      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
    46      "parent_descs": [
    47        "wpkh(0219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa)#ulvysxd0"
    48      ],
    49      "category": "receive",
    50      "amount": 49.97998167,
    51      "label": "",
    52      "vout": 1
    53    }
    54  ],
    55  "hex": "020000000001016476318b50e920be026e7fbd53d8f6ccf4f94242f7163a7487c6cd5c6d571e010000000000ffffffff0280841e00000000001600149df415e84b640458f0b468e6e37ed5a2ac9be29d5766e729010000001600146f9bdbee7e0ff8374f2ff4f0e6abfb5aaed5459a02483045022100ac4575df9a551a8b94153a029d475b2ad65a62ad6488d917897297333368a27d0220275c4c57c7a375df30b37b90ae8dab3da04cfa1619aa0eb655e7ae9c92d0107f01210219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa00000000"
    56}
    
  4. maflcko commented at 10:23 am on August 14, 2023: member
    If the output was spent in the meantime, it won’t be shown in listunspent. Can you confirm it wasn’t spent?
  5. samyan commented at 10:41 am on August 14, 2023: none

    If the output was spent in the meantime, it won’t be shown in listunspent. Can you confirm it wasn’t spent?

    No, it has not been spent. In fact, I’ve been doing several tests for 1 week to understand what the problem is. To test I simply send funds to wallet X, execute listunspent, it shows me the inputs. After 1 day, I execute listunspent to the same wallet again and it returns empty.

  6. maflcko commented at 11:29 am on August 14, 2023: member
    Can you reproduce with -mocktime or setmocktime?
  7. samyan commented at 11:58 am on August 14, 2023: none

    -mocktim

    Still the same.

  8. maflcko commented at 3:47 pm on August 14, 2023: member
    What are the exact steps to reproduce with mocktime?
  9. samyan commented at 4:30 pm on August 14, 2023: none

    What are the exact steps to reproduce with mocktime?

    Sincerely I don’t know I understood you correctly, but these were my steps:

    Set system time:

    bitcoin-core.cli setmocktime 0

    Then

    bitcoin-core.cli listunspent 0 9999999 [\"bcrt1qnh6pt6ztvsz93u95drnwxlk452kfhc5ad9uk6z\"]

  10. sipa commented at 5:21 pm on August 14, 2023: member
    Do you have 100 blocks on top of the one that created your UTXO? Without that it’ll be immature, and possibly not listed.
  11. samyan commented at 5:24 pm on August 14, 2023: none

    Do you have 100 blocks on top of the one that created your UTXO? Without that it’ll be immature, and possibly not listed.

    Yes I have, and as I said above, after moving the funds and executing the listunspent command, it returns the inputs perfectly. After a day, I run the listunspent command again and I get empty.

  12. sipa commented at 5:25 pm on August 14, 2023: member
    Apologies, I should have read more. If something actually disappears from listunspent (without being reorged out), that sounds like a bug.
  13. samyan commented at 5:28 pm on August 14, 2023: none

    Apologies, I should have read more. If something actually disappears from listunspent (without being reorged out), that sounds like a bug.

    Don’t worry. I also think it seems to be a bug but I don’t know… So I will continue to do more tests.

  14. mzumsande commented at 8:05 pm on August 14, 2023: contributor

    Are you stopping bitcoind and restarting it after 24h, or do you keep it running? If it’s the former, are you sure that the correct wallet is loaded? If it’s the latter, does an actual restart fix the problem?

    Sincerely I don’t know I understood you correctly, but these were my steps: (…)

    I think the question was that when you create the output and then use setmocktime to mock time to a timestamp to the future (instead of waiting for 24h), whether you see the same effect immediately without actually waiting.

  15. samyan commented at 8:21 pm on August 14, 2023: none

    Are you stopping bitcoind and restarting it after 24h, or do you keep it running? If it’s the former, are you sure that the correct wallet is loaded? If it’s the latter, does an actual restart fix the problem?

    Sincerely I don’t know I understood you correctly, but these were my steps: (…)

    I think the question was that when you create the output and then use setmocktime to mock time to a timestamp to the future (instead of waiting for 24h), whether you see the same effect immediately without actually waiting.

    Not, i’m not stopping bitcoind, it is part of systemctl and it is running in background. The wallet is loaded correctly. I’ve tried to restart anyways but the problem continues…

    Regarding setmocktime, I have set the time 3 days forward and with the test transaction that I have carried out today, it is still perfect. So it’s not a mocktime problem.

    I will try the same tomorrow and share you the screen.

  16. furszy commented at 8:24 pm on August 14, 2023: member
    Just in case, please also print the current tip hash vs tomorrow’s tip hash.
  17. samyan commented at 8:37 pm on August 14, 2023: none

    Just in case, please also print the current tip hash vs tomorrow’s tip hash.

    What do you mean with “tip”? Sorry, i’m a bit new to some things. :)

  18. furszy commented at 8:41 pm on August 14, 2023: member

    Just in case, please also print the current tip hash vs tomorrow’s tip hash.

    What do you mean with “tip”? Sorry, i’m a bit new to some things. :)

    np. The bitcoin-cli getbestblockhash output.

  19. samyan commented at 8:46 pm on August 14, 2023: none

    Just in case, please also print the current tip hash vs tomorrow’s tip hash.

    What do you mean with “tip”? Sorry, i’m a bit new to some things. :)

    np. The bitcoin-cli getbestblockhash output.

    Thank you for clarify. So, today is: 2432724b29f73abdb2fc345db5e47a19d0ed286f7b7b85ad3485e2a53764f9b6

    image

    It remains to try again tomorrow.

  20. samyan commented at 8:19 am on August 15, 2023: none

    Hello guys! 11 hours have passed, here it is 10:19 CET and the result is as follows:

    0debian@vps-b4e8a731:~$ bitcoin-core.cli -rpcport=10001 -rpcuser=bitcoin -rpcpassword=bitcoin getbestblockhash
    12432724b29f73abdb2fc345db5e47a19d0ed286f7b7b85ad3485e2a53764f9b6
    2
    3debian@vps-b4e8a731:~$ bitcoin-core.cli -rpcport=10001 -rpcuser=bitcoin -rpcpassword=bitcoin listunspent 0 9999999 [\"bcrt1qlmxyvxl4akf0nz54tw0hpu5vzdasj37ef7hm4s\"]
    4[
    5]
    

    The problem persists and it is something strange.

  21. maflcko commented at 8:29 am on August 15, 2023: member
    What is gettransaction 16e...?
  22. samyan commented at 8:32 am on August 15, 2023: none

    What is gettransaction 16e...?

     0{
     1  "amount": 0.00000000,
     2  "fee": -0.00001692,
     3  "confirmations": 6,
     4  "blockhash": "1db6dbff417219a6858d532c42bb670fb418fb26e48fbc44e586133af8ecfccd",
     5  "blockheight": 232,
     6  "blockindex": 2,
     7  "blocktime": 1692031801,
     8  "txid": "16e0b64735f1e4748a88ef414ec7b70861c4467ffef0dba1e628cc21a312507e",
     9  "wtxid": "9926759aedc24a9e4fd627e7e12168872caa8062e17380c3a15d27111f34cbb7",
    10  "walletconflicts": [
    11  ],
    12  "time": 1692031024,
    13  "timereceived": 1692031024,
    14  "bip125-replaceable": "no",
    15  "details": [
    16    {
    17      "address": "bcrt1qlmxyvxl4akf0nz54tw0hpu5vzdasj37ef7hm4s",
    18      "category": "send",
    19      "amount": -0.00200000,
    20      "label": "",
    21      "vout": 0,
    22      "fee": -0.00001692,
    23      "abandoned": false
    24    },
    25    {
    26      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
    27      "category": "send",
    28      "amount": -0.01797208,
    29      "label": "",
    30      "vout": 1,
    31      "fee": -0.00001692,
    32      "abandoned": false
    33    },
    34    {
    35      "address": "bcrt1qlmxyvxl4akf0nz54tw0hpu5vzdasj37ef7hm4s",
    36      "parent_descs": [
    37        "wpkh(027010673b2ef060a189aa3d44e4ce7f38dd21a51cf0a4697c96ec236953a72671)#j88a7unx"
    38      ],
    39      "category": "receive",
    40      "amount": 0.00200000,
    41      "label": "",
    42      "vout": 0
    43    },
    44    {
    45      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
    46      "parent_descs": [
    47        "wpkh(0219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa)#ulvysxd0"
    48      ],
    49      "category": "receive",
    50      "amount": 0.01797208,
    51      "label": "",
    52      "vout": 1
    53    }
    54  ],
    55  "hex": "020000000001015d9ba7aeb44f0d9fb3582e061531de9d8799e45fb273ed1915279ba2c33d5a800000000000ffffffff02400d030000000000160014fecc461bf5ed92f98a955b9f70f28c137b0947d9586c1b00000000001600146f9bdbee7e0ff8374f2ff4f0e6abfb5aaed5459a0247304402207065c88d9624f35c647c00412f137ad7e8876c008d76b66c2d6fc6df4cf5d7ce022070ea34669032b3acbad7b883a04ec30f14d047cd72b3a90d8116b443bd114e0901210219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa00000000"
    56}
    
  23. maflcko commented at 8:35 am on August 15, 2023: member
    And gettxout 16e0b64735f1e4748a88ef414ec7b70861c4467ffef0dba1e628cc21a312507e 0?
  24. samyan commented at 8:36 am on August 15, 2023: none

    Nothing.

  25. maflcko commented at 8:43 am on August 15, 2023: member
    And listsinceblock 1db6dbff417219a6858d532c42bb670fb418fb26e48fbc44e586133af8ecfccd?
  26. samyan commented at 8:44 am on August 15, 2023: none

    And listsinceblock 1db6dbff417219a6858d532c42bb670fb418fb26e48fbc44e586133af8ecfccd?

      0{
      1  "transactions": [
      2    {
      3      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
      4      "category": "send",
      5      "amount": -0.00198790,
      6      "label": "",
      7      "vout": 0,
      8      "fee": -0.00001210,
      9      "confirmations": 0,
     10      "trusted": true,
     11      "txid": "2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc",
     12      "wtxid": "0a3881070849fd239993efd953fdb4286fc6746d8402d3d7773bb7a194f90fe5",
     13      "walletconflicts": [
     14      ],
     15      "time": 1692057608,
     16      "timereceived": 1692057608,
     17      "bip125-replaceable": "no",
     18      "abandoned": false
     19    },
     20    {
     21      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
     22      "parent_descs": [
     23        "wpkh(0219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa)#ulvysxd0"
     24      ],
     25      "category": "receive",
     26      "amount": 0.00198790,
     27      "label": "",
     28      "vout": 0,
     29      "confirmations": 0,
     30      "trusted": true,
     31      "txid": "2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc",
     32      "wtxid": "0a3881070849fd239993efd953fdb4286fc6746d8402d3d7773bb7a194f90fe5",
     33      "walletconflicts": [
     34      ],
     35      "time": 1692057608,
     36      "timereceived": 1692057608,
     37      "bip125-replaceable": "no"
     38    },
     39    {
     40      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
     41      "parent_descs": [
     42        "wpkh(0219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa)#ulvysxd0"
     43      ],
     44      "category": "immature",
     45      "amount": 25.00000000,
     46      "label": "",
     47      "vout": 0,
     48      "confirmations": 1,
     49      "generated": true,
     50      "blockhash": "2432724b29f73abdb2fc345db5e47a19d0ed286f7b7b85ad3485e2a53764f9b6",
     51      "blockheight": 237,
     52      "blockindex": 0,
     53      "blocktime": 1692031801,
     54      "txid": "3a36cbddc28ae6aa5ba0bc6bf569e35ae75e7bf5566b9b33fee8d4d6af65fbb2",
     55      "wtxid": "5b82423702f3cd74eccb506f586fa966b912fafd61505f967ecf4332b17259ec",
     56      "walletconflicts": [
     57      ],
     58      "time": 1692031801,
     59      "timereceived": 1692031801,
     60      "bip125-replaceable": "no"
     61    },
     62    {
     63      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
     64      "parent_descs": [
     65        "wpkh(0219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa)#ulvysxd0"
     66      ],
     67      "category": "immature",
     68      "amount": 25.00000000,
     69      "label": "",
     70      "vout": 0,
     71      "confirmations": 2,
     72      "generated": true,
     73      "blockhash": "008b5d18aa4cd82a12dbcf151a98146d92aaeedffe9144cc5e76e9d29f92c870",
     74      "blockheight": 236,
     75      "blockindex": 0,
     76      "blocktime": 1692031801,
     77      "txid": "7271186631080a6a12382dd5ac360640ed56c9dff8e5ff5b0e60b160b35b9f6f",
     78      "wtxid": "a320be54cb430fcfa53424b824d60db625570e0f29f11348f955b7f91f70ea48",
     79      "walletconflicts": [
     80      ],
     81      "time": 1692031801,
     82      "timereceived": 1692031801,
     83      "bip125-replaceable": "no"
     84    },
     85    {
     86      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
     87      "parent_descs": [
     88        "wpkh(0219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa)#ulvysxd0"
     89      ],
     90      "category": "immature",
     91      "amount": 25.00000000,
     92      "label": "",
     93      "vout": 0,
     94      "confirmations": 4,
     95      "generated": true,
     96      "blockhash": "113743f76680ab2193cd4a52b679dc6d7a2c7dc5ebdb7bd3cafab49b677a46c6",
     97      "blockheight": 234,
     98      "blockindex": 0,
     99      "blocktime": 1692031801,
    100      "txid": "5cf1e06700ed104ebe98e7c5688e5d6ae31be90d1b8a12cffff013d33d0ace23",
    101      "wtxid": "c15ad72a7f71360a973382e12c522165011b86697960b1f40e640b05c296610f",
    102      "walletconflicts": [
    103      ],
    104      "time": 1692031801,
    105      "timereceived": 1692031801,
    106      "bip125-replaceable": "no"
    107    },
    108    {
    109      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
    110      "parent_descs": [
    111        "wpkh(0219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa)#ulvysxd0"
    112      ],
    113      "category": "immature",
    114      "amount": 25.00000000,
    115      "label": "",
    116      "vout": 0,
    117      "confirmations": 3,
    118      "generated": true,
    119      "blockhash": "76db40212b6581055f023df79b703d5ef99d75faa6a3037cf19c07386dfe7336",
    120      "blockheight": 235,
    121      "blockindex": 0,
    122      "blocktime": 1692031801,
    123      "txid": "bf66fc9c0d92cb3697146d17c38006ca2768c9ef340f2f3a5e1f20ca4e874661",
    124      "wtxid": "e7ba0e99584d802c38403f3f8acd490685ba5087bea1d55612bb4a78078d3464",
    125      "walletconflicts": [
    126      ],
    127      "time": 1692031801,
    128      "timereceived": 1692031801,
    129      "bip125-replaceable": "no"
    130    },
    131    {
    132      "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
    133      "parent_descs": [
    134        "wpkh(0219dc00bb73cc4a155aa34bdb0b11c4ed2b4573c1f559875258fae530a26bb5aa)#ulvysxd0"
    135      ],
    136      "category": "immature",
    137      "amount": 25.00000000,
    138      "label": "",
    139      "vout": 0,
    140      "confirmations": 5,
    141      "generated": true,
    142      "blockhash": "44626003d384cd6f43e747e94cf7429eff3c922b8d30c994d62de4a68f298978",
    143      "blockheight": 233,
    144      "blockindex": 0,
    145      "blocktime": 1692031801,
    146      "txid": "78bfa22b87fe1b71df4a79761f10f7eadc9fab648a138051baab0f522fc500b5",
    147      "wtxid": "8c9b3a4025bf8be6ac9a62c4c11aa9c8827ed47044a9c4ff63bb2a474a9e857f",
    148      "walletconflicts": [
    149      ],
    150      "time": 1692031801,
    151      "timereceived": 1692031801,
    152      "bip125-replaceable": "no"
    153    }
    154  ],
    155  "removed": [
    156  ],
    157  "lastblock": "2432724b29f73abdb2fc345db5e47a19d0ed286f7b7b85ad3485e2a53764f9b6"
    158}
    
  27. maflcko commented at 8:50 am on August 15, 2023: member
    And getrawtransaction 2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc 2 (or 1)?
  28. samyan commented at 8:59 am on August 15, 2023: none

    And getrawtransaction 2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc 2 (or 1)?

    getrawtransaction 2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc 2

     0{
     1  "txid": "2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc",
     2  "hash": "0a3881070849fd239993efd953fdb4286fc6746d8402d3d7773bb7a194f90fe5",
     3  "version": 2,
     4  "size": 192,
     5  "vsize": 110,
     6  "weight": 438,
     7  "locktime": 0,
     8  "vin": [
     9    {
    10      "txid": "16e0b64735f1e4748a88ef414ec7b70861c4467ffef0dba1e628cc21a312507e",
    11      "vout": 0,
    12      "scriptSig": {
    13        "asm": "",
    14        "hex": ""
    15      },
    16      "txinwitness": [
    17        "3045022100af0cbcb6d56565fa1d14be57c0ed025655c8186b3e33a2f91668b71f79d0d2f102200dca7d17b043ca95df85b6b6cc9406ee787784a5fa22654224e6b31ddfa6d21301",
    18        "027010673b2ef060a189aa3d44e4ce7f38dd21a51cf0a4697c96ec236953a72671"
    19      ],
    20      "sequence": 4294967295
    21    }
    22  ],
    23  "vout": [
    24    {
    25      "value": 0.00198790,
    26      "n": 0,
    27      "scriptPubKey": {
    28        "asm": "0 6f9bdbee7e0ff8374f2ff4f0e6abfb5aaed5459a",
    29        "desc": "addr(bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0)#7tr23dlx",
    30        "hex": "00146f9bdbee7e0ff8374f2ff4f0e6abfb5aaed5459a",
    31        "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
    32        "type": "witness_v0_keyhash"
    33      }
    34    }
    35  ],
    36  "hex": "020000000001017e5012a321cc28e6a1dbf0fe7f46c46108b7c74e41ef888a74e4f13547b6e0160000000000ffffffff0186080300000000001600146f9bdbee7e0ff8374f2ff4f0e6abfb5aaed5459a02483045022100af0cbcb6d56565fa1d14be57c0ed025655c8186b3e33a2f91668b71f79d0d2f102200dca7d17b043ca95df85b6b6cc9406ee787784a5fa22654224e6b31ddfa6d2130121027010673b2ef060a189aa3d44e4ce7f38dd21a51cf0a4697c96ec236953a7267100000000"
    37}
    

    getrawtransaction 2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc 1

     0{
     1  "txid": "2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc",
     2  "hash": "0a3881070849fd239993efd953fdb4286fc6746d8402d3d7773bb7a194f90fe5",
     3  "version": 2,
     4  "size": 192,
     5  "vsize": 110,
     6  "weight": 438,
     7  "locktime": 0,
     8  "vin": [
     9    {
    10      "txid": "16e0b64735f1e4748a88ef414ec7b70861c4467ffef0dba1e628cc21a312507e",
    11      "vout": 0,
    12      "scriptSig": {
    13        "asm": "",
    14        "hex": ""
    15      },
    16      "txinwitness": [
    17        "3045022100af0cbcb6d56565fa1d14be57c0ed025655c8186b3e33a2f91668b71f79d0d2f102200dca7d17b043ca95df85b6b6cc9406ee787784a5fa22654224e6b31ddfa6d21301",
    18        "027010673b2ef060a189aa3d44e4ce7f38dd21a51cf0a4697c96ec236953a72671"
    19      ],
    20      "sequence": 4294967295
    21    }
    22  ],
    23  "vout": [
    24    {
    25      "value": 0.00198790,
    26      "n": 0,
    27      "scriptPubKey": {
    28        "asm": "0 6f9bdbee7e0ff8374f2ff4f0e6abfb5aaed5459a",
    29        "desc": "addr(bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0)#7tr23dlx",
    30        "hex": "00146f9bdbee7e0ff8374f2ff4f0e6abfb5aaed5459a",
    31        "address": "bcrt1qd7dahmn7plurwne07ncwd2lmt2hd23v62zz2y0",
    32        "type": "witness_v0_keyhash"
    33      }
    34    }
    35  ],
    36  "hex": "020000000001017e5012a321cc28e6a1dbf0fe7f46c46108b7c74e41ef888a74e4f13547b6e0160000000000ffffffff0186080300000000001600146f9bdbee7e0ff8374f2ff4f0e6abfb5aaed5459a02483045022100af0cbcb6d56565fa1d14be57c0ed025655c8186b3e33a2f91668b71f79d0d2f102200dca7d17b043ca95df85b6b6cc9406ee787784a5fa22654224e6b31ddfa6d2130121027010673b2ef060a189aa3d44e4ce7f38dd21a51cf0a4697c96ec236953a7267100000000"
    37}
    

    Seems to be the same output.

  29. maflcko commented at 9:01 am on August 15, 2023: member
    If you spend an output, it will be no longer unspent, thus listunspent won’t return it
  30. maflcko added the label Questions and Help on Aug 15, 2023
  31. maflcko added the label Wallet on Aug 15, 2023
  32. maflcko commented at 9:02 am on August 15, 2023: member
    Closing for now. Let us know if you have any other questions.
  33. maflcko closed this on Aug 15, 2023

  34. samyan commented at 9:03 am on August 15, 2023: none

    If you spend an output, it will be no longer unspent, thus listunspent won’t return it

    If you spend an output, it will be no longer unspent, thus listunspent won’t return it

    Obviously but I have not spent any. The address bcrt1qlmxyvxl4akf0nz54tw0hpu5vzdasj37ef7hm4s should contain the unspent outputs that I sent yesterday but today it does not.

  35. maflcko commented at 9:04 am on August 15, 2023: member
    Txid 2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc, created 9 hours ago, spent the 16e0b64735f1e4748a88ef414ec7b70861c4467ffef0dba1e628cc21a312507e : 0 output.
  36. samyan commented at 9:06 am on August 15, 2023: none

    Txid 2a98703475934131304b5d1a3cfae4795b8f83709e6965771bdf02f600bfaffc, created 9 hours ago, spent the 16e0b64735f1e4748a88ef414ec7b70861c4467ffef0dba1e628cc21a312507e : 0 output.

    Okay, we’re going to check it again. Thanks for your help.

  37. bitcoin locked this on Aug 14, 2024

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: 2024-12-21 15:12 UTC

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