Hot answers tagged

5

Nope. Not 1 bit. A balance (in this context) is the sum of all UTXO's for a given address. There is no limit on the number of UTXO's or their total amount (from the perspective of how the blockchain works and the blockchains limitations). Software interpreting the balance may have limitations on consuming, processing and/or displaying a number beyond a ...


4

No, there does not such thing as initialfreecoins=10000000. However mining on regtest is not resource hungry and nearly instant. It's the only way to get coins. To get coins on regtest you first need a address to mine those coins to. An address can be created with bitcoin-cli -regtest getnewaddress. To mine and payout to this address use with <address&...


4

The main difference between signet and regtest is that signet is an actual network, as opposed to a sandboxed environment. In regtest, the network topology is entirely manual. You spin up nodes, and manually establish connections between them. You have exact control over what blocks are mined and when. This is great for testing things like consensus logic, ...


3

Use regtest Chain selection options: -regtest Enter regression test mode, which uses a special chain in which blocks can be solved instantly. This is intended for regression testing tools and app development. -testnet Use the test chain Using this mode, you can manually mine blocks by issuing the following command, where ...


3

You can build your miner with a bash command: $ while true; do bitcoin-cli -regtest generate 1; sleep 300; done You'l get a block every 5'. If you want a better simulation of mainnet you could use a rndom sleep


3

Signet is more comparable to testnet than it is to regtest. Regtest is for private use and testing things. Even if signet were available, it is still useful to have your own blockchain for testing where you can generate coins, blocks, forks, and reorgs at will. It allows tests to run quickly and for a specific set of conditions to be tested. There is no ...


2

Yes this is possible and (at least with clightning) very easy to do. I always use this script by Nadav Ivgi from his spark wallet. The key part is this : (MIT license by Nadav Ivgi) $ mkdir -p /tmp/spark-env/{btc,ln1,ln2} $ bitcoind --regtest --datadir=/tmp/spark-env/btc --printtoconsole $ lightningd --network regtest --lightning-dir /tmp/spark-env/ln1 --...


1

Yes... ... But it is going to be a lot of work. First you should look at BIP 199 which defines htlc scripts. However that alone will only tell you how to create a htlc output. But with the transaction itself it is not done. You need to use the right channel state and keys so you could read BOLT 02, 03 and 05 to learn about the peer protocol and messages ...


1

You have to add the absolute time/blockheight before OP_CHECKLOCKTIMEVERIFY in the script to depict how long you want to lock the transaction. Also you are using 150 as the CLTV parameter. Anything that is below 500M is dubbed as block height. Given you are using 150, that means that transaction is not spendable until 150 blocks, which should mean it is ...


1

As the two nodes do not agree on segwit's activation scheme on regtest, the solution is to set a common version bits parameter to both of them. For example, adding vbparams=segwit:0:99999999999 in the two nodes' .conf files will work.


1

I don't understand the difference between listaddressgroupings and getnewaddress listaddressgroupings is very different from getnewaddress. listaddressgroupings just shows you addresses from your wallet that have been used. getnewaddress gives you a new address for you to receive Bitcoin at. What address is it? That address is an address in your wallet. ...


1

The miner can generate a block candidate with the getblocktemplate call, which uses certain heuristics to construct an approximation of an fee-optimised block given the current local mempool state. 1) The question in regards to when to begin mining Generally, the miner will want to begin mining the next block as soon as the strong chain is extended, ...


1

This is not possible because the regtest network is limited to 15000 regtest BTC. Unlike mainnet and testnet, it's halving interval is 150 blocks which limits the number of regtest BTC on one chain to 15000 (actually just under that). On regtest, you don't actually need to make outputs which reach the dust threshold. The default behavior is to allow non-...


1

As long as your nodes are running on separate ports and using separate data directories, you should have no issues running multiple networks. Note that you may run into resource issues, especially with regular spinning HDDs, if both networks have high requirements for disk writes and reads at any point.


1

To you, but with a delay. What you're observing is the maturity period: the coins generated by a block can only be moved after there are another 100 blocks on top. If you generate another 100, your balance will start increasing.


1

A transaction is confirmed by including it in a block. This means that you have to mine a block which includes the transaction. You can do this using the generate command.


Only top voted, non community-wiki answers of a minimum length are eligible