--- Log opened Thu Jan 17 00:00:24 2019 02:18 -!- TamasBlummer [~Thunderbi@p200300DD67243B26200CC345B02CE51E.dip0.t-ipconnect.de] has joined #rust-bitcoin 02:29 < stevenroose> andytoshi: any progress on that jsonrpc PR making it http-agnostic? 04:49 -!- icota [~igor@141-136-181-17.dsl.iskon.hr] has quit [Ping timeout: 250 seconds] 04:56 -!- icota [~igor@141-136-181-17.dsl.iskon.hr] has joined #rust-bitcoin 07:32 -!- dpc [dpcmatrixo@gateway/shell/matrix.org/x-paxmwfehlgmjylcq] has quit [Ping timeout: 250 seconds] 07:33 -!- savil [savilmatri@gateway/shell/matrix.org/x-bzphonelnclapblc] has quit [Ping timeout: 260 seconds] 07:34 -!- michaelsdunn1 [~michaelsd@38.126.31.226] has joined #rust-bitcoin 07:34 -!- michaelsdunn1 [~michaelsd@38.126.31.226] has quit [Changing host] 07:34 -!- michaelsdunn1 [~michaelsd@unaffiliated/michaelsdunn1] has joined #rust-bitcoin 07:37 -!- dpc [dpcmatrixo@gateway/shell/matrix.org/x-yfutgbqvmakqadgj] has joined #rust-bitcoin 07:39 -!- savil [savilmatri@gateway/shell/matrix.org/x-hexmgyhwerhbdauc] has joined #rust-bitcoin 08:00 < BlueMatt> ariard: no big deal, the fuzzer has been super super helpful in catching lots of bugs, so I'm feeling a bit more confident in those code paths being testable and am less worried about things 08:00 < BlueMatt> andytoshi: can we get a secp version bump for fuzztarget fixes (sorry...) 08:31 -!- TamasBlummer [~Thunderbi@p200300DD67243B26200CC345B02CE51E.dip0.t-ipconnect.de] has quit [Quit: TamasBlummer] 08:48 -!- TamasBlummer [~Thunderbi@p200300DD67243B26200CC345B02CE51E.dip0.t-ipconnect.de] has joined #rust-bitcoin 09:28 < dongcarl> Running into a weird panic on our bitcoin_hashes integration PR: https://github.com/rust-bitcoin/rust-bitcoin/pull/215#issuecomment-455257847 09:28 < dongcarl> Please help, as getting bitcoin_hashes in would be superb 09:40 -!- elichai2 [uid212594@gateway/web/irccloud.com/x-jcalcczeksobmhrn] has joined #rust-bitcoin 09:43 -!- wumpus [~ircclient@pdpc/supporter/professional/wumpus] has quit [Quit: WeeChat 2.2] 09:44 -!- wumpus [~ircclient@pdpc/supporter/professional/wumpus] has joined #rust-bitcoin 12:18 < nothingmuch> dongcarl: i believe what's happenning is that strason consumes the value of input.[0].previous_input.txid, sending it to the new from_hex which requires explicit lifetime (&'a str, whereas previously it took &str) 12:19 < nothingmuch> i still don't grok lifetime stuff properly, so i'm not sure what would be the correct thing to do, but i find the lack of 'a here surprising: https://github.com/rust-bitcoin/bitcoin_hashes/blob/95a1f761618e23b32a219dda9f6c0c88ee2c9e81/src/hex.rs#L42 12:20 < dongcarl> hmm 12:20 < dongcarl> nothingmuch: thanks so much for debugging this 12:20 < dongcarl> How did you come to that conclusion may I ask? 12:21 < nothingmuch> the test failure arises from trying to decode the json form of the tx, which is produced correctly, the actual error is invalid type: string "0000000000000000000000000000000000000000000000000000000000000000", expected a borrowed string', libcore/result.rs:1009:5 12:22 < nothingmuch> (line 796 in invalid type: string "0000000000000000000000000000000000000000000000000000000000000000", expected a borrowed string', libcore/result.rs:1009:5 12:22 < nothingmuch> oops, sorry, in src/blockdata/transaction.rs 12:22 < dongcarl> Yeah I guess I didn't know that explicit lifetimes could cause problems like this 12:23 < nothingmuch> the main change is that OutPoint.txid changed type, in the commit you bisected, line 167 -> 170 calls from_hex on the bitcoin hashes type instead of util hash 12:25 < nothingmuch> the util::hash::Sha256dHash from_hex type seems to take a reference, whereas the bitcoin_hashes from_hex has that lifetime tag which if i understand correctly implies it'd be borrowed 12:26 < dongcarl> nothingmuch: ahhhh that makes sense 12:26 < nothingmuch> bear in mind i'm still really new to rust, so there's a good chance this is terribly confused 12:26 < dongcarl> I'm trying things out with the `'a` removed 12:26 < dongcarl> fingers crossed 12:29 < gwillen> if you google for "expected a borrowed string" there are a bunch of posts about serde 12:29 < gwillen> I don't know if the issue is the same but there's some discussion of things to try 12:30 < dongcarl> gwillen: Ah I see 12:31 < dongcarl> Yeah nothingmuch's solution didn't seem to solve it 12:31 < dongcarl> But that `'a` can be safely removed! 12:31 < nothingmuch> i didn't realize i had a solution ;-) 12:32 < nothingmuch> fwiw, it seemed to match https://github.com/serde-rs/serde/issues/1413 which indeed i did find by googling the error 12:32 < nothingmuch> based on dtolnay's reduced example i assumed something similar was going on with the txid of the input 12:33 < dongcarl> Hmmm yeah, I'm gunna PR the `'a` removal, and then take a look at that 12:42 < nothingmuch> when actually returning the hash type, the end the new version calls Self::from_slice(&vec), https://github.com/rust-bitcoin/bitcoin_hashes/blob/92fffa3e682cb478cd7c1883745e68c6393fd00f/src/sha256d.rs#L61-L63, which is pretty much the same as the old https://github.com/rust-bitcoin/rust-bitcoin/blob/master/src/util/hash.rs#L209-L225 12:42 < nothingmuch> i think the actual difference is in the first use of the string arg: https://github.com/rust-bitcoin/rust-bitcoin/blob/master/src/util/hash.rs#L208 vs. https://github.com/rust-bitcoin/bitcoin_hashes/blob/95a1f761618e23b32a219dda9f6c0c88ee2c9e81/src/hex.rs#L47 12:45 < nothingmuch> dongcarl: did you remove 'a from https://github.com/rust-bitcoin/bitcoin_hashes/blob/95a1f761618e23b32a219dda9f6c0c88ee2c9e81/src/hex.rs#L111 ? 12:46 < dongcarl> Yeah I did 12:46 < dongcarl> Didn't seem to help 12:47 < dongcarl> :-/ 12:48 < nothingmuch> i need to give up for tonight, no brain left, i'll try to learn about lifetimes properly tomorrow, and make more sense of this if you haven't already by then 12:58 < dongcarl> Gnite! 14:02 -!- michaelsdunn1 [~michaelsd@unaffiliated/michaelsdunn1] has quit [Remote host closed the connection] 14:02 -!- michaelsdunn1 [~michaelsd@unaffiliated/michaelsdunn1] has joined #rust-bitcoin 14:02 -!- michaelsdunn1 [~michaelsd@unaffiliated/michaelsdunn1] has quit [Remote host closed the connection] 14:16 < nothingmuch> dongcarl: had a shower, and channeled my inner emin... what's the sane approach towards modifying deps? 14:17 < nothingmuch> thinking about it logically, lifetime tags are not relevant for the returned data, given that it's allocated within the from_hex construction and ownership is passed to call site 14:17 < nothingmuch> so i think the failure has to be that Vec::, given that that's the only thing consuming the borrowed string of hex digits 14:18 < nothingmuch> so i think the 'a is not being passed to Vec::::from_hex when it should be 14:18 < nothingmuch> given that it is ultimately borrowed from srason 14:20 < nothingmuch> (now attempting to learn how to modify a dep, i also barely know cargo ;_;) 14:20 < dongcarl> I think you specify path= 14:22 < nothingmuch> yep, that seems to work 14:24 < dongcarl> nothingmuch: try my bitcoin_hashes integration branch with “—feature=use-serde” 14:25 < nothingmuch> ah, i believe i was building against 0.2 previously fwiw 14:26 < nothingmuch> either what i thought would fix it didn't fix it, will w/ your branch 14:26 < nothingmuch> (what was working was your suggestion for cargo) 14:29 < nothingmuch> combined-*integration-improvements or *integration-additions? 14:29 < nothingmuch> looks like combined rebased additions 14:53 < dongcarl> nothingmuch: ah sorry didn't specify for you 14:53 < dongcarl> you should be building against 0.2 + your patches 14:53 < dongcarl> those branches are stale 14:54 < dongcarl> as in, compile https://github.com/rust-bitcoin/rust-bitcoin/pull/215 against 0.2 + your patches 14:54 < nothingmuch> ah, thanks 15:09 < dongcarl> nothingmuch: just to make sure we're on the same page 15:09 < dongcarl> Here's the one that's failing for me 15:09 < dongcarl> `cargo +stable test --color always --verbose --features=use-serde-decimal` 15:10 < nothingmuch> yep, took that out of the travis build 15:11 < nothingmuch> however, the page-space has many other degrees of freedom i'm likely lost in... but then again, no other way to learn ;-) 15:12 < dongcarl> nothingmuch: Haha I agree, if you need anything from me make sure to mention me in messages so I get notified 15:13 < nothingmuch> thanks! though i expect my showerthoughts expanding brain delusions will soon subside and i'll finally go to sleep, i've been up for far too long 15:15 < dongcarl> Haha yes, sleep is important! 16:44 -!- sdaftuar [~sdaftuar@238.90.227.35.bc.googleusercontent.com] has quit [Ping timeout: 245 seconds] 16:45 -!- elichai2 [uid212594@gateway/web/irccloud.com/x-jcalcczeksobmhrn] has quit [Quit: Connection closed for inactivity] 16:47 -!- sdaftuar [~sdaftuar@238.90.227.35.bc.googleusercontent.com] has joined #rust-bitcoin 17:52 -!- schmidty_ [~schmidty@104-7-216-111.lightspeed.austtx.sbcglobal.net] has joined #rust-bitcoin 18:00 -!- Netsplit *.net <-> *.split quits: schmidty 20:11 -!- schmidty_ [~schmidty@104-7-216-111.lightspeed.austtx.sbcglobal.net] has quit [Remote host closed the connection] 20:13 -!- schmidty [~schmidty@unaffiliated/schmidty] has joined #rust-bitcoin 20:18 -!- schmidty [~schmidty@unaffiliated/schmidty] has quit [Ping timeout: 246 seconds] 20:22 < dongcarl> andytoshi: why is BIP62 implemented in rust-bitcoin if it's been withdrawn? Perhaps we can feature-gate it? 20:48 -!- schmidty [~schmidty@unaffiliated/schmidty] has joined #rust-bitcoin 21:27 -!- schmidty [~schmidty@unaffiliated/schmidty] has quit [Ping timeout: 245 seconds] 22:09 -!- schmidty [~schmidty@unaffiliated/schmidty] has joined #rust-bitcoin 22:15 -!- schmidty [~schmidty@unaffiliated/schmidty] has quit [Ping timeout: 268 seconds] 22:29 -!- schmidty [~schmidty@unaffiliated/schmidty] has joined #rust-bitcoin 22:33 -!- schmidty [~schmidty@unaffiliated/schmidty] has quit [Ping timeout: 240 seconds] 23:37 -!- icota_ [~igor@4-178.dsl.iskon.hr] has joined #rust-bitcoin 23:40 -!- icota [~igor@141-136-181-17.dsl.iskon.hr] has quit [Ping timeout: 245 seconds] 23:52 -!- schmidty [~schmidty@unaffiliated/schmidty] has joined #rust-bitcoin 23:57 -!- schmidty [~schmidty@unaffiliated/schmidty] has quit [Ping timeout: 252 seconds] --- Log closed Fri Jan 18 00:00:24 2019