Bitcoin full node and query server

October 2020

Archive of the libbitcoin Slack #general channel.

Thursday, October 1, 2020

X
xraid07:15
ahhhhh ok . so when v4 is mature to deploy we could expect be able to connect specter and other eco-system connects through bitcoin-cli JSON-RCP API ?
neillm12:20
You can connect today, you just need to run an instance
X
xraid17:20
as in connect today with 3.6 using bitcoin-cli ?
neillm17:21
as in connect today with master (4.0) using bitcoin-cli
X
xraid17:21
well master do not sync
neillm17:21
I am currently running a sync'd testnet, which is publicly accessible
X
xraid17:23
with sync i was refering yo mainnet - any idea of time frame - - -
neillm17:23
I've sync'd mainnet multiple times
X
xraid17:24
i tried did not reach 1.0
neillm17:24
Try again? Report error?
neillm17:32
Some outdated info, but there's a section on bitcoin-cli there: https://github.com/thecodefactory/libbitcoin-web
X
xraid17:34
yes tried that
bitcoin-cli -rpcconnect=127.0.0.1 -rpcport=9071 
to syncing master and it worked but the master did never finnish syncing up to 1.0
(edited)
neillm17:35
I'm not saying it's production ready, but it's possible to get a clean sync
$ bitcoin-cli -rpcconnect=testnet2.libbitcoin.net -rpcport=29071 getblockcount 
1837026
X
xraid17:36
You should be in sales ...
😁

Friday, October 2, 2020

neillm00:42
^ Probably an insult to people that are actually in sales ... 😅

Friday, October 9, 2020

neillm22:58
@xraid Did you ever report the sync error of mainnet on v4 btw? I'm curious. There should be 2 ways you can sync it right now: 1) Edit the config to use libconsensus, or 2) Set a high checkpoint.

Tuesday, October 20, 2020

X
xloem23:25
Hey, when we're writing new client apps, and want to submit bug fixes and minor features, should we be using version3 or master?
pmienk23:43
that would depend upon the fix/feature
master for things intended for v4, version3 for fixes to the release, both for fixes that haven't been removed as issues in a future release. features would likely be master only, but its negotiable

Wednesday, October 21, 2020

evoskuil01:10
V4 is good for everything except full node/server.
X
xloem22:25
thanks
I'm having trouble figuring out how to get my unconfirmed transactions using libbitcoin-client (to not respend the utxos) ... is this possible?
evoskuil22:57
You can do it with BX using address subscriptions or new tx notifications. The small amount of code in bx uses -client, so it shows you how.
X
xloem23:23
I tried subscriptions using 3.5, but I didn't seem to get notifications for transactions that were in the pool before I connected: does that just mean I did something wrong?
evoskuil23:52
Nope, that’s how it works.
Nodes don’t provide a tx pool search interface. If you want that you need to maintain the tx pool yourself (be a node). You can query BS for this and it does provide search over the pool.
2 replies · xloem · last Oct 23, 2020
X
xloem05:17
I believe I'm connecting to BS community servers via libbitcoin-client. I don't see that libbitcoin-server has a way to find transactions already in the pool ... are you sure this isn't a missing feature?
X
xloem11:50
I think I understand that you're saying the only pool access in BS is search-by-transaction and subscribe-to-new
evoskuil23:55
There are BS community servers.

Thursday, October 22, 2020

N
narodnik20:21
How's everyone doing? 😄
😰 1
I've been working on a ZK virtual machine: https://github.com/narodnik/sapvi
👍 1
6 replies · neillm · last Oct 23, 2020
neillm02:12
The repo is missing a ton of source -- won't build.
neillm02:13
   Compiling sapvi v0.1.0 (/home/neillm/builds/sapvi)
error: couldn't read src/jubjub.rs: No such file or directory (os error 2)

error: couldn't read src/sha256.rs: No such file or directory (os error 2)

error: aborting due to previous error

error: couldn't read src/mimc.rs: No such file or directory (os error 2)

error: aborting due to previous error

error: aborting due to previous error

error: couldn't read src/vmtest.rs: No such file or directory (os error 2)

error: could not compile `sapvi`.

To learn more, run the command again with --verbose.
warning: build failed, waiting for other jobs to finish...
error: aborting due to previous error

error: couldn't read src/blake.rs: No such file or directory (os error 2)

error: aborting due to previous error

error: couldn't read src/simple.rs: No such file or directory (os error 2)

error: aborting due to previous error

error: couldn't read src/spend.rs: No such file or directory (os error 2)

error: aborting due to previous error

error: couldn't read src/mint2.rs: No such file or directory (os error 2)

error: aborting due to previous error

error: couldn't read src/mint.rs: No such file or directory (os error 2)

error: aborting due to previous error

error: couldn't read src/bits.rs: No such file or directory (os error 2)

error: aborting due to previous error

error: couldn't read src/eq.rs: No such file or directory (os error 2)

error: aborting due to previous error

error: couldn't read src/basic_minimal.rs: No such file or directory (os error 2)

error: aborting due to previous error
neillm02:14
Maybe related?
$ ./run_jubjub.sh 
+ racket lisp/jj.rkt
+ python scripts/compile.py --supervisor jj.psm --output jubjub.zcd
  File "scripts/compile.py", line 53
    print(*args, file=sys.stderr)
          ^
SyntaxError: invalid syntax
+ exit 1
neillm02:15
Let me know the reqs, could probably help get into shape.
neillm02:26
Derp, nevermind -- python3 required.
neillm02:29
Still some weirdness:
$ cargo fmt --all
Error: file `/home/neillm/builds/sapvi/src/basic_minimal.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/bits.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/blake.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/eq.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/jubjub.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/mimc.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/mint.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/mint2.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/pedersen_hash.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/sha256.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/simple.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/spend.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/vmtest.rs` does not exist
Error: file `/home/neillm/builds/sapvi/src/zec.rs` does not exist
jungly20:23
you even threw in some lisp in there! 😄
fpelliccioni22:01
Hey @narodnik. I sent you a DM

Friday, October 23, 2020

X
xloem11:56
I'm looking into adding unconfirmed transaction enumeration to libbitcoin-server, likely by adding to interface/transaction_pool . Sound good?
X
xloem12:09
orrrr maybe it would make more sense to add to fetch_history in interface/blockchain ...
X
xloem14:32
annnd the source of fetch_history shows that unconfirmed transactions should be included, so not having them must be just a bug
evoskuil14:41
The v4 node’s tx pool index is not fully implemented.
(edited)
X
xloem16:03
So if I want to find all payments for an address in a transaction pool, it sounds like I would want to add that to v3.
(edited)
neillm16:05
If you subscribe after address generation you don't need to query, but if you want to query, then yes, I think so. Or just fix the v4 index 😉
evoskuil16:47
V4 has a tx pool index, implemented by @pmienk, but it’s not integrated yet. V3 does not. The tx pool exists, but there is no way to query the store for them, as the node doesn’t need such an index.
(edited)
The server provides a client-server query interface for it, but due to the lack of index it’s not populated.
X
xloem20:57
can a version4 client connect to a version3 server?
neillm22:01
Yes and no -- several of the calls have changed (protocol wise), so they are incompatible. For the ones that haven't (such as fetch-height), yes.
evoskuil22:17
I forget the details, but there should be backward compat for non-dropped (previously deprecated) commands.
neillm23:42
Hrm, pretty sure things like fetch-history are incompatible at the moment
And any calls that take a payment_key instead of address (even subscribe there)
I suppose compat may be possible in some cases
evoskuil23:45
There are multiple versions of those commands.
neillm23:49
Right, but I mean to say that v4 deprecates a number of v3 commands via protocol changes, making compat not quite there. So while a v4 client can connect to v3 servers for some commands, it will likely get errors on the deprecated commands. Same for v3 to v4. I believe the errors returned in all incompat cases make sense (e.g. object not found)
I think we're kind of saying the same thing btw, me just in a roundabout way 😉
evoskuil23:53
Sounds like that work isn’t finished. ;)
neillm23:56
Hrm, I'd have to check, but I think there's at least client API compat calls that take addrs like v3, so there's some sort of work done there. But not protocol matched, so there's still a versioned call mismatch (i.e. bx v3 to v4 server won't work, but code written against v3 may in more cases)
As for exposing the config (discussed via github issues), it should be straight-forward to have a link on the web interface expose it.

Tuesday, October 27, 2020

vdeurzen11:23
Seems like BTC hasn't had a new block in ~2 hours 🤔