--- Day changed Mon Nov 12 2018 00:44 < ariard> stevenroose, andytoshi: seems that's 15.0 broke some serializing stuff : https://github.com/rust-bitcoin/rust-lightning/pull/249#issuecomment-437721084 00:46 < ariard> maybe c42252c but not sure, don't have the changelog details in head 00:48 < stevenroose> ariard: hmm, what I said on GitHub doesn't make sense, .bitcoin_hash() does exactly what you did there manually 00:50 < stevenroose> Pretty sure c42252c would have produced errors if it changed anything significant 00:52 < ariard> bitcoin_hash() doesn't solve it 00:53 < ariard> okay, maybe in the commits moving network::serialize thing ? 00:54 < stevenroose> ariard: particular reason why you used hash-of-serialization instead of bitcoin_hash in the first place? 00:54 < stevenroose> `.txid()` fixes it 00:55 < stevenroose> it 00:55 < stevenroose> it's the version that doesn't hash witnesses 00:55 < ariard> yes fixes it 00:55 < stevenroose> ariard: I updated the PR 00:55 < ariard> well, ask to BlueMatt didn't write this test 00:56 < stevenroose> I spotted some more `*txid = Sha256dHash::from_data(serialize(...))` 00:57 < stevenroose> don't seem to be tested, but I'll fix them 00:57 < ariard> stevenroose> it's the version that doesn't hash witnesses// so it's the 0.14 related thing ? 00:57 < ariard> (a 00:57 < ariard> *a 00:57 < stevenroose> yeah I think from some version on, the condensus_encode defaulted to witnesses 00:57 < stevenroose> IIRC 00:59 < stevenroose> those two catches were in the fuzzer, fwiw, that's why they were not catched by tests probably 00:59 < ariard> ah, yeah quite annoying 01:19 < stevenroose> ariard: how can I efficiently build all the fuzz targets? never touched the fuzzing in rust-bitcoin before 01:23 < stevenroose> ariard: hmm once I get the failures about main, it seems like all the rest builds, should be ok now 02:27 < ariard> stevenroose: cd fuzz/ && cargo test && ./travis-fuzz.sh, if it's that what you want 04:32 < TamasBlummer> @stevenroose why take p2p out of spv? what would be its other use? database reference is in one p2p class because it manages the set of peers as they connect/disconnect or misbehave in the db 07:32 < dpc> stevenroose: In the `address_from_script` you gave me, I'm getting panics on `secp256k1::key::PublicKey::from_slice(&secp, &script.as_bytes()[1..66]).unwrap();` (`index 66 out of range for slice of length 35`). Just letting you know. :) . I guess it just doesn't handle compressed keys. 07:40 < dpc> I made it `[1..(script.len() - 1)]` and now it works. 10:18 < stevenroose> dpc: oh that makes sense, thanks! 10:20 < stevenroose> TamasBlummer: generic p2p crate could be used to build a full node on or a network sniffer 10:29 < TamasBlummer> a network sniffer could be built using rust-bitcoin and plain sockets. p2p is more about managing contacts (find/ban/balance peers). SPV is probably not the right name for the project (will find one like hammersbald) as SPV is a certain type of validating transactions as claimed by POW majority. A node could be more picky about what the right fork is and may also store more data than needed for SPV. 10:29 < TamasBlummer> There is a range between "perfect lockstep" of Bitcoin Core nodes and SPV. 12:26 <+andytoshi> ariard: 0.15 change serialization for 0-input transactions 12:26 <+andytoshi> to always use segwit 12:26 <+andytoshi> but your code was always broken for segwit transactions 13:26 < stevenroose> TamasBlummer: was thinking of a package with functionality along the lines of this one: https://godoc.org/github.com/btcsuite/btcd/peer basically lets you create peers with a socket address and has easy ways to push messages to a peer, react on incoming messages from a peer and then does some optimization regarding inventories 13:27 < stevenroose> andytoshi: any chance we can get rust-bitcoincore-rpc in the rust-bitcoin org? We published a v0.1.0 that works with the old jsonrpc, but as soon as #20 lands, we can push v0.2.0 working with http-less jsonrpc 14:43 < TamasBlummer> @stevenroose: eventually extract it once spv does what it should 15:08 < stevenroose> TamasBlummer: what is the status of p2p in spv? I was going through it a bit, out of curiosity, trying to abstract it a bit from the spv context. What I didn't particularly liked was that all processing happens in that one method instead on a per-Peer basis 15:09 < stevenroose> But well I don't know anything about mio-paradigms 15:51 <+andytoshi> stevenroose: yeah sure 15:51 <+andytoshi> do i need to move it or do you? 15:52 <+andytoshi> i think jeandudey might need to take action to make that happen .. maybe i need to add him to the rust-bitcoin org first 15:52 < stevenroose> > You don’t have the permission to create repositories on rust-bitcoin 15:52 < stevenroose> it comes from stevenroose/rust-bitcoindrpc 15:53 <+andytoshi> kk, lemme see if i can figure this out 15:53 <+andytoshi> so, i can fork it to rust-bitcoin 15:53 <+andytoshi> but that's not really what we want to do 15:54 <+andytoshi> are you willing to add me as an admin to rust-bitcoindrpc? i can de-admin myself after i do the move 15:54 < stevenroose> yeah either I need permission to move it, or you fork it and then I can set the fork as the main 15:54 < stevenroose> yeah no worries :p 15:54 <+andytoshi> can you set the fork as main? i think that requires emailing a github employee 15:54 < stevenroose> andytoshi: nah you can do that 15:55 < stevenroose> at least I've seen it being done.. perhaps you only get the chance if you remove the old main 15:55 < stevenroose> if they give you a dialog, try renaming it to rust-bitcoincore-rpc 15:55 <+andytoshi> interesting .. with rust-secp i had quite a bit of trouble .. originally it was dpc's repo then i moved it, then he deleted it and bizarrely steveklablik's fork became the main 15:55 < stevenroose> ah 15:56 < stevenroose> hmm, yeah never did it myself. I just thought it was possible as I saw it happen once. Perhaps they were lucky? :D 15:56 <+andytoshi> i emailed github and they fixed it 15:57 < stevenroose> That will probably not have become any easier then, given the acquisition 15:57 < stevenroose> Got the invitation? 15:58 <+andytoshi> yep .. well, no, but i typed the invitation URL and it worked 15:58 <+andytoshi> which i guess is a reasonable UX :P 15:58 <+andytoshi> i think i'm just a regular member, i don't have a Settings link 16:02 < stevenroose> yeah I can just add collaborators, can't make them admin or so if you're not in an organization :/ 16:03 < stevenroose> http://imagizer.imageshack.com/img923/8379/lUVRy4.png 16:03 < stevenroose> Btw, if you fork, you'd be the only fork :D 16:03 < stevenroose> So we could be lucky there :D 16:03 < stevenroose> "reasonable UX" 16:05 <+andytoshi> hm weird. ok, i'll just fork te rust-bitcoin then 16:07 <+andytoshi> kk done. invited you as an admin 16:07 <+andytoshi> oh, actually, what if you try transferring ownership to me and then i try transferring to rust-bitcoin? 16:07 <+andytoshi> or maybe we should just stick with the fork :P 16:08 < stevenroose> deleted fork and renamed 16:08 <+andytoshi> heyyy look at that 16:08 < stevenroose> so now I can refork for myself :D 16:08 <+andytoshi> https://github.com/rust-bitcoin/rust-bitcoincore-rpc just looks like it's the main repo 16:09 < stevenroose> yeah because I deleted the other main 16:09 < stevenroose> now we just lost issues, but were only me and dpc anyway 16:09 <+andytoshi> ok, fine, i admin that i'm just an old fogey emailing github whenever things get hard 16:09 <+andytoshi> admit 16:09 < stevenroose> dpc: ^^ rust-bitcoin/rust-bitcoincore-rpc 16:09 < stevenroose> Can't blame you, I come here to cry when Rust bites me :D 16:10 < stevenroose> k thanks, so next up is jsonrpc and then I can take a look at using it for the functionary, to see how the API feels in that context. 16:10 < stevenroose> I already ported reserves, works fine. 16:11 <+andytoshi> yeah, jsonrpc might take a bit longer because there's some other stuff i want to get done before i can look at it 16:38 < TamasBlummer> @stevenroose: status of rust-bitcoin-spv: The mio based p2p engine is solid and high performance, able to find peers, stay connected and download the chain. Development stalled for months because I focused on Hammersbald. 16:40 < TamasBlummer> @stevenroose: I used futures 0.2 which then got yanked. waiting for futures 3.0 (and async/wait at best) befor continuing with more intelligent load balancing between peers. 16:40 < _cryptosignal_me> Hello people:) 16:40 < TamasBlummer> @stevenroose: Implemented BIP158 and currently working on making it a BIP157/BIP158 server and client 16:51 < stevenroose> TamasBlummer: I like the BIP158 implementation! Thinking if they would make sense in bitcoin::util or so. (Only SipHasher as dep, no?) 16:52 < stevenroose> TamasBlummer: is the p2p currently single-thread? 16:52 < TamasBlummer> yes single thread for mio event loop and futures to connect 16:54 < TamasBlummer> @stevenroose: I prefer building bigger working pieces with building blocks that are isolated with interfaces (traits) and move blocks evtl into another repo once they proved to be useful. 16:55 < TamasBlummer> @stevenroose: starting a project too early for every functionality leads to overengineering in my experience as one works toward anticipated instead of actual use 16:56 < stevenroose> TamasBlummer: I agree, that's basically why I'm thinking of taking out the p2p part as a single building block 16:57 < stevenroose> it should just produce some form of stream of incoming messages from peers and have a way to send outgoing messages 17:05 < TamasBlummer> as said, will consider once it does it work within the spv node. Representing it as two streams seems sufficient only until you dive into the problem. That is the premature overengineering I do not want. 17:07 < TamasBlummer> I prefer keeping in mind that I might want to separate it for now. 17:08 < TamasBlummer> If you look at it now you see that it is already as lightly coupled as possible with the rest. 21:54 < dongcarl> andytoshi: sgeisler and I were looking at the rust version again 21:54 < dongcarl> And it seems the debian people updated to 1.24 21:55 < sgeisler> :party: 21:56 < dongcarl> Here's a link: https://qa.debian.org/madison.php?package=rustc 22:25 < dongcarl> PEOPLE DON'T YOU SEE WE CAN NOW HAVE NICE THINGS? 22:29 < dpc> :tada: 22:32 < dpc> Before you know it, we are all going to be coding in Rust 2018 Edition. ;D 22:39 < dongcarl> Woop woop