380 Commits

Author SHA1 Message Date
Antoine Poinsot
030bfadaf7
bitcoind: decrease the sync progress roundup threshold 2022-12-14 16:51:17 +01:00
Antoine Poinsot
4560bc9ed2
bitcoind: move roundup_progress() to utils and unit test it 2022-12-14 16:51:16 +01:00
edouard
88c807d599
Merge #223: Gui add launcher
63be34b3d887d0d39f861b6ae46996d64a245b18 Add confirm network step to gui (edouard)

Pull request description:

ACKs for top commit:
  edouardparis:
    Self-ACK 63be34b3d887d0d39f861b6ae46996d64a245b18

Tree-SHA512: 5952af35c6559ab91aeed330973dd2496a35d246c18d87266f81abb65effcfc4da11005c1e15ab7923d4f4db3709079987b0c3e527ca7611c244737ea8f10505
2022-12-14 12:28:32 +01:00
edouard
63be34b3d8 Add confirm network step to gui
User is asked which network to start with.
This is a required step in case the user
start the software without a console and
can not set himself the network or launch
the install for another non existing network.
2022-12-14 11:55:13 +01:00
edouard
a4299877eb
Merge #205: gui: add recovery feature
f43d99f0fbd851d9817b3668b26953f81c77c1f9 gui: add panel recovery (edouard)
f2facdf1641eaa0241201dee23e13dec63e534cc gui: add create_recovery command to client (edouard)
f4afed4d6a14ad9ea515a69ebf0c584106423075 bump liana master (edouard)

Pull request description:

  After #182, this fixes #180.

ACKs for top commit:
  edouardparis:
    Self-ACK f43d99f0fbd851d9817b3668b26953f81c77c1f9

Tree-SHA512: 49fa2582b5ef405b3ac79ce621792918afe00b0f6fd64bce626f84c11fc97c2b96459f3daf424e625eda31842f85982b0bf76da71afd36bd848e9a4d8fe96c27
2022-12-14 11:38:07 +01:00
edouard
f43d99f0fb gui: add panel recovery 2022-12-14 09:21:07 +01:00
edouard
f2facdf164 gui: add create_recovery command to client 2022-12-14 09:21:07 +01:00
edouard
f4afed4d6a bump liana master 2022-12-14 09:21:07 +01:00
Antoine Poinsot
ad1f0e20b1
Merge #182: Recovery command to sweep "expired" coins
ba994ff8ff01d04fd31ed77cf7f66e0862e68e17 commands: do not underestimate the size of created transactions (Antoine Poinsot)
46a94d6c8eb144484a4b0df2ddbd48b32d4d096f qa: test recovery 'sweep' transaction creation (Antoine Poinsot)
3b5cbd5122fa53d0247e82dd7fc703b5d0a4bae3 qa: introduce a sign_and_broadcast utility (Antoine Poinsot)
d362885b85107b616447899d5eaaa5ba1b55c170 qa: record the recovery xpub too (Antoine Poinsot)
a69fb625ea3b8dfbfa1bf384e001f167fd04ff86 qa: use a CSV of 10 for recovery (Antoine Poinsot)
a78f46fa2fc5337c51d1eaa6ac6bbee04cfdf437 [refactoring] jsonrpc: sort command names alphabetically (Antoine Poinsot)
c09ae3f87bc8bb2391d88d1a718b35d4a6c568fa commands, jsonrpc: add a new 'createrecovery' command (Antoine Poinsot)
3d5d0134b4b5bc06910a89d23def36de5b548c30 commands: fix the capacity of input vectors in create_spend (Antoine Poinsot)
f2312593da8b27c6c6a69c7b0463959369c5acb6 commands: check for dust outputs in the PSBT sanity checks (Antoine Poinsot)
9f23161a53ad32d03d4ec464c48a819862dbf3e5 commands: correct the max feerate value (Antoine Poinsot)
54410cd9c435e1e6228b985d78e55b357c2368b8 database: allow to query coins by their spending status (Antoine Poinsot)

Pull request description:

  A new command that provides a simple way for a user to sweep all the coins whose timelocked recovery path is available.

  The first part of #180. Note this also contains a number of drive-by fixes that i noticed while coding this up.

ACKs for top commit:
  darosior:
    self-ACK ba994ff8ff01d04fd31ed77cf7f66e0862e68e17 -- tested by Edouard on the GUI

Tree-SHA512: 002cb8602370fe3bec0692fe7bbe9e7af494b43756d3092da99b37e4ce2837bcdfcfb3afe7043900eb41c70de12e2129e19363b9efe41cee91c7f1f7c2824fb0
2022-12-13 18:17:14 +01:00
Antoine Poinsot
05bbb3eef2
Merge #215: update bitcoind connection and be more robust at startup
acd6929831964d643565f8f22b552f74613a3a1d doc: update for bitcoind 24.0.1 release (Antoine Poinsot)
650101525d890f50290989bd58c367024a69115c bitcoind: set minimum required version to 24.0 (Antoine Poinsot)
9211d849c191ff5d2552bde681edaa7038c8d049 bitcoind: be less stupid when loading the watchonly wallet (Antoine Poinsot)

Pull request description:

  Fixes #210
  Fixes #209
  Fixes #213

ACKs for top commit:
  darosior:
    self-ACK acd6929831964d643565f8f22b552f74613a3a1d

Tree-SHA512: 8cacf41b0e00faed877462dc57b595265ff2936937d45535d1be2b42fd1bf80df2928ccacbefd43f82d88a728aca898a8549899380e341de8b8e74d34ec74642
2022-12-13 18:00:17 +01:00
Antoine Poinsot
1e56c58166
Merge #214: descriptors: rule-out 0-value timelocks
b74a6ffc16740c1a8c0b93a8b4aa34bc1a1b819a qa: unflake test_rescan_edge_cases (Antoine Poinsot)
f6db9c6677ca43c51afbacbf4036cfe55f5539b1 descriptors: rule out null timelocks (Antoine Poinsot)

Pull request description:

  Fixes #208.

ACKs for top commit:
  darosior:
    self-ACK b74a6ffc16740c1a8c0b93a8b4aa34bc1a1b819a

Tree-SHA512: 3d4ed44f3b376e897bd28d11b9e1ce367d6cdf28f70472f39b3939d2cf25580302a81542131086aa1b9a028161f0eabe084efdd54a55703d0a2d4150eac84ae9
2022-12-13 17:47:27 +01:00
Antoine Poinsot
b74a6ffc16
qa: unflake test_rescan_edge_cases
We weren't waiting for lianad to be back to the same height as bitcoind.
Necessarily it could happen that sorted_coins() would return an empty
list.

Fixes #142 (did 50 successful runs of the test)
2022-12-13 16:59:57 +01:00
Antoine Poinsot
f6db9c6677
descriptors: rule out null timelocks
They are valid by consensus, not by Miniscript.
2022-12-13 16:59:56 +01:00
Antoine Poinsot
acd6929831
doc: update for bitcoind 24.0.1 release
Technically the minimum we support is 24.0 but let's not nudge people to
install a version with a buggy wallet.

Fixes #210
2022-12-13 16:37:52 +01:00
Antoine Poinsot
650101525d
bitcoind: set minimum required version to 24.0 2022-12-13 16:37:52 +01:00
Antoine Poinsot
9211d849c1
bitcoind: be less stupid when loading the watchonly wallet
Only load it if isn't there already.
2022-12-13 16:14:20 +01:00
Antoine Poinsot
de629cc075
Merge #211: gui: disable daemon jsonrpc client for windows
37562608ecd9471fe37ea123fe21512b6d373068 gui: disable daemon jsonrpc client for windows (edouard)

Pull request description:

  It is not certain that uds_windows will work so we prefer
  to remove it.

ACKs for top commit:
  darosior:
    utACK 37562608ecd9471fe37ea123fe21512b6d373068. That sounds more reasonable, and removes 8 dependencies 🎉.

Tree-SHA512: f0af1ceba6dc0881d5265497c606ff9916ba9a64cb94a79b4e4b4ecce9c3800fc796f0cd2eb620abf14793efb413b88cee202ce800a4e4c237e761ef5d2ab528
2022-12-13 16:00:47 +01:00
Antoine Poinsot
ba994ff8ff
commands: do not underestimate the size of created transactions
We were truncating when computing the virtual size of satisfactions.
2022-12-13 15:37:58 +01:00
Antoine Poinsot
46a94d6c8e
qa: test recovery 'sweep' transaction creation 2022-12-13 15:34:25 +01:00
Antoine Poinsot
f9359869f7
Merge #140: Bootstrappable builds
ef20b782301bae2fdfb842dfd89a749e60cb449e guix: make the builds actually reproducible (Antoine Poinsot)
72a332d2caf6c139d20855203d107fe3b185ba7d guix: fix the dependencies listing for the GUI container (Antoine Poinsot)
4a38040acf12dd457ac5f29a24f4b3800114255c guix: documentation (Antoine Poinsot)
37a28dbf7d5a22426d1844ef792d04e604e5b91b guix: use a lighter environment for building the daemon (Antoine Poinsot)
ae0b24f97494a7a859578ab6191187c4405a225f guix: allow to limit the number of cores dedicated to the build (Antoine Poinsot)
940c28d072c449295f6e1225446b829bea2d3053 guix: use patchelf to strip interpreter and RPATH (Antoine Poinsot)
3906a1b5bc5e7f57925981b4dd009fc6b13de7c1 guix: reproducible builds of the GUI (Antoine Poinsot)
8dda896e4b2c4baa69b5e1b839bfaf47b9b36320 guix: Linux reproducible builds of the daemon (Antoine Poinsot)

Pull request description:

  This introduces reproducible and bootstrappable builds of our softwares by using [Guix](https://guix.gnu.org/). This is heavily inspired by the work on Guix [that was done in the Bitcoin Core project](https://github.com/bitcoin/bitcoin/tree/master/contrib/guix). For an intro to reproducible builds with Guix see [this post](https://guix.gnu.org/blog/2020/reproducible-computations-with-guix/).

  For details, see the documentation introduced in this PR. Apologies for the poor commit history.

ACKs for top commit:
  darosior:
    ACK ef20b782301bae2fdfb842dfd89a749e60cb449e

Tree-SHA512: 58800170a8fd0822129f1fefa23c8a8cb68e8758a56b3ea9933b41cff1eff7691ed735a28f156395b76c18447044f2ba5a3f4cd519696667b6df90e27e20d3f6
2022-12-13 14:52:42 +01:00
Antoine Poinsot
ef20b78230
guix: make the builds actually reproducible
Paths to the dependencies affect the symbols in the binary
2022-12-13 14:50:59 +01:00
Antoine Poinsot
72a332d2ca
guix: fix the dependencies listing for the GUI container 2022-12-13 14:50:59 +01:00
Antoine Poinsot
4a38040acf
guix: documentation
This is directly inspired from the Bitcoin Core project's documentation.
This especially copies some stuff written by Carl Dong.
2022-12-13 14:50:58 +01:00
Antoine Poinsot
37a28dbf7d
guix: use a lighter environment for building the daemon
Special case the GUI dependencies to the GUI's container
2022-12-13 14:50:57 +01:00
Antoine Poinsot
ae0b24f974
guix: allow to limit the number of cores dedicated to the build 2022-12-13 14:50:57 +01:00
Antoine Poinsot
940c28d072
guix: use patchelf to strip interpreter and RPATH 2022-12-13 14:50:56 +01:00
Antoine Poinsot
3906a1b5bc
guix: reproducible builds of the GUI
The GUI is using an insane MSRV so i had to patch my way through in
order to be able to build some dependencies.
2022-12-13 14:50:56 +01:00
Antoine Poinsot
8dda896e4b
guix: Linux reproducible builds of the daemon 2022-12-13 14:50:55 +01:00
edouard
37562608ec gui: disable daemon jsonrpc client for windows
It is not sure uds_windows will work so we prefer
to remove it.
2022-12-13 12:20:20 +01:00
edouard
bb9a41727e
Merge #201: fix gui: wrong event selection on home panel
ea6d4f9b6374ea9e8873a4eb768feef11caaa48f fix gui: wrong event selection on home panel (edouard)

Pull request description:

  Because pending events are in a different list
  that confirmed event. The wrong list item was
  selected when user tried to click on a pending
  event.

ACKs for top commit:
  edouardparis:
    Self-ACK ea6d4f9b6374ea9e8873a4eb768feef11caaa48f

Tree-SHA512: c0eef61c53a75f1fa746494bf9abc151a31f37d05616a8615eba2f3d3f6fe2573d96adef3b5ad7efd7f30b71d01afb012d5166cdfcbf9a1215752cbdfb43d6ae
2022-12-12 15:49:34 +01:00
Antoine Poinsot
3b5cbd5122
qa: introduce a sign_and_broadcast utility 2022-12-09 12:27:50 +01:00
Antoine Poinsot
d362885b85
qa: record the recovery xpub too 2022-12-09 12:27:49 +01:00
Antoine Poinsot
a69fb625ea
qa: use a CSV of 10 for recovery 2022-12-09 12:27:49 +01:00
Antoine Poinsot
a78f46fa2f
[refactoring] jsonrpc: sort command names alphabetically 2022-12-09 12:27:48 +01:00
Antoine Poinsot
c09ae3f87b
commands, jsonrpc: add a new 'createrecovery' command
This is a new command dedicated to the recovery usecase. For now it's
dead simple: sweep all coins that are available through the recovery
path to a given address.
2022-12-09 12:27:47 +01:00
Antoine Poinsot
3d5d0134b4
commands: fix the capacity of input vectors in create_spend
They were based on the expected size of the outputs vector...
2022-12-09 12:20:39 +01:00
Antoine Poinsot
f2312593da
commands: check for dust outputs in the PSBT sanity checks 2022-12-09 12:19:02 +01:00
Antoine Poinsot
9f23161a53
commands: correct the max feerate value
We should have a functional test for this...
2022-12-09 12:19:02 +01:00
Antoine Poinsot
54410cd9c4
database: allow to query coins by their spending status 2022-12-09 12:19:01 +01:00
Antoine Poinsot
b3337193a4
Merge #153: Fill in non_witness_utxo when creating Spend PSBTs
07e5ea3fd2afae4e1b84abc57b0937c6e74ab3b0 commands: fill non_witness_utxo field in PSBT inputs for createspend (Antoine Poinsot)

Pull request description:

  Fixes #133.

ACKs for top commit:
  edouardparis:
    ACK 07e5ea3fd2afae4e1b84abc57b0937c6e74ab3b0

Tree-SHA512: 57a211482e138d55c95494a070e67e2f353a8688cf0f546b71de18c5ea6c2b752231c84c6281b8ed59487cb057fc8265139b59598b3bed79bb6482a5cdd00a7c
2022-12-09 12:18:43 +01:00
edouard
ea6d4f9b63 fix gui: wrong event selection on home panel
Because pending events are in a different list
that confirmed event. The wrong list item was
selected when user tried to click on a pending
event.
2022-12-09 11:45:45 +01:00
Antoine Poinsot
07e5ea3fd2
commands: fill non_witness_utxo field in PSBT inputs for createspend
We are still in segwit v0, so signers need it!!
2022-12-09 10:49:49 +01:00
edouard
ca771e3e00
Merge #183: fix installer: import_descriptor next button
2d788d5bffc1b237dc6be3c09ca2e13afcdeca67 fix installer: import_descriptor next button (edouard)

Pull request description:

  Next button was grey although the descriptor form
  is not empty.

ACKs for top commit:
  edouardparis:
    Self-ACK 2d788d5bffc1b237dc6be3c09ca2e13afcdeca67

Tree-SHA512: ad98aa33691c24e65ca0c04af47b007f4c9a5abcfd376f9a84c9a2de40a39f34f24aceebdd209ad9dd92d5ec7a7d3806ff61063ec45eb7c00a5f4b986e8c97ba
2022-12-09 09:03:12 +01:00
edouard
abe69a1f8f
Merge #184: gui: bump ledger_bitcoin_client 0.1.1
2a609a8eb69fc14d6bb9f58e0043a95ca9713d04 gui: bump ledger_bitcoin_client 0.1.1 (edouard)

Pull request description:

  This version of the client contains a fix
  required for the no inputs recognized warning.

ACKs for top commit:
  edouardparis:
    Self-ACK 2a609a8eb69fc14d6bb9f58e0043a95ca9713d04

Tree-SHA512: 39cff0aee6c66909948cdef9354e71c204f0e03696e71c641919d9f749463316da470b296197c794940e412cf13cf43139f48cda76b010652e8c6dc309f227f3
2022-12-09 08:57:05 +01:00
edouard
d0abaec485
Merge #175: gui: bump liana for release
9fa3cde2991a9ea66ba0f5e2b1da3f40e3d8165e bump liana:master (edouard)

Pull request description:

  TODO: bump this branch again, after milestone is done

ACKs for top commit:
  edouardparis:
    Self-ACK 9fa3cde2991a9ea66ba0f5e2b1da3f40e3d8165e

Tree-SHA512: 55941cba40ffc1ff82ea43a7b46fca40e424a529a76c727ae25a276b88fca2b5a45c9481d43cb30298662b4b1b04a121969cee6407b92b91db7b8dec012e6eb0
2022-12-09 08:08:47 +01:00
edouard
2a609a8eb6 gui: bump ledger_bitcoin_client 0.1.1
This version of the client contains a fix
required for the no inputs recognized warning.
2022-12-08 18:08:10 +01:00
edouard
2d788d5bff fix installer: import_descriptor next button
Next button was grey although the descriptor form
is not empty.
2022-12-08 17:30:28 +01:00
Antoine Poinsot
f03b617490
Merge #176: Friendlier bitcoind startup error handling
0306773cdca15009d3bf2c6eb0c3ebd8e7fb7989 daemon: log and exit 1 on startup error, don't panic (Antoine Poinsot)
13b2b8eef4dd5deafe04b2330b469067afd0b12c bitcoind: immediately set the default retry limit (Antoine Poinsot)
b0ef121e91209e1c69ddefa0765d7a93d1dfb569 bitcoind: accurate connection sanity checks at startup (Antoine Poinsot)

Pull request description:

  We were not properly treating warming up errors when bitcoind was starting up. Also, better to just log as error and `exit` with `1` instead of panic'ing on a daemon startup error.

  See the commit messages for details.

  Fixes #134
  Fixes #163

ACKs for top commit:
  edouardparis:
    ACK 0306773cdca15009d3bf2c6eb0c3ebd8e7fb7989

Tree-SHA512: e14a72456104682ccff30d88e21303447065d371aed7279461595795eb938ba823578f05cc47704d996dbe570d12f467b91a88d58363511864e6a1f10eb76004
2022-12-08 17:23:11 +01:00
edouard
9fa3cde299 bump liana:master 2022-12-08 15:49:04 +01:00
Antoine Poinsot
d385e99726
Merge #179: gui: cleanup the README.
f1e072bb5f59e0bffb6d39b340bb5be85c132be4 gui: cleanup the README. (Antoine Poinsot)

Pull request description:

  Fixes #105.

ACKs for top commit:
  darosior:
    self-ACK f1e072bb5f59e0bffb6d39b340bb5be85c132be4 -- trivial

Tree-SHA512: a1ef68eacdca0c40ac9ff701b29016ee50cbca15528d8cb028f33532369c109e214ca31be9ec89a9ff59baebd1f3e9d706f9e64303df00462471f64f7f487899
2022-12-08 15:02:53 +01:00