--- Log opened Tue Jan 18 00:00:33 2022 01:30 -!- elsirion_ [~quassel@gateway/tor-sasl/elsirion] has quit [Remote host closed the connection] 02:45 -!- duderonomy [~duderonom@c-73-158-190-156.hsd1.ca.comcast.net] has quit [Quit: My MacBook has gone to sleep. ZZZzzz…] 02:56 -!- belcher_ is now known as belcher 07:02 -!- mauz [~mauz@2a01:e0a:994:7ed0:c869:daa8:3abc:ab54] has joined #bitcoin-rust 07:13 -!- mauz [~mauz@2a01:e0a:994:7ed0:c869:daa8:3abc:ab54] has quit [Quit: Leaving...] 09:29 -!- enick_368 [~afilini-m@2001:bc8:1828:245::2] has quit [Quit: Bridge terminating on SIGTERM] 09:30 -!- enick_536 [~afilini-m@2001:bc8:1828:245::2] has joined #bitcoin-rust 09:59 -!- duderonomy [~duderonom@c-73-158-190-156.hsd1.ca.comcast.net] has joined #bitcoin-rust 10:27 -!- trev [~trev@user/trev] has quit [Quit: trev] 10:39 < belcher> im trying to use "Script::from(&a_vec8)" from rust-bitcoin, cargo says "the trait `From<&Vec>` is not implemented for `bitcoin::Script`" how to fix and make it compile? cargo suggests "use std::convert::From::from;" but that doesnt work 10:56 < jeremyrubin> are you sure it takes a reference and not a clone? 10:57 < jeremyrubin> may also help to do a .into() 10:57 < jeremyrubin> lastly, i doubt From is implemented because i dont think Script can always be parsed from vec? Maybe it's a fallible API? 10:58 < jeremyrubin> yeah i only see From> not reference 10:59 < belcher> haha yes found it, it takes a .clone() 10:59 < belcher> it seems i saw the error message and tried adding a & automatically 10:59 < belcher> Script::from() definitely exists, its used by rust-lightning and a few other places in rust-bitcoin 10:59 < belcher> thanks for the help! 10:59 < jeremyrubin> np 11:00 < jeremyrubin> Script::from considered unsafe :p 11:01 < belcher> where does it say that? 11:08 < jeremyrubin> it doesnt 11:09 < jeremyrubin> but you have no guarantees that you have a valid script 11:09 < jeremyrubin> it's not memeory unsafe, just api unsafe 11:09 < belcher> im obtaining it from the witness of a transaction, so i assume the bitcoin core node already did the checking.... also if it really is invalid i think nothing bad should happen (famous last words lol) 11:10 < jeremyrubin> e.g., issues you could run into: > 10k byte script, invalid pushdata fragment, unmatched if/else, etc. 11:10 < jeremyrubin> i think that's fair for that use case, idk what you wanted it for 11:11 < belcher> its doing an off-chain contract similar to LN, reading the hash preimage from the witness of a transaction, and then using that preimage to spend another utxo 11:11 < belcher> if the script is anything weird then it will detect it and return a None, and then not try to create any new transaction 11:13 < jeremyrubin> kk 11:23 -!- plsm_ [~plsm@host86-145-154-181.range86-145.btcentralplus.com] has joined #bitcoin-rust 11:37 -!- dunxen [~dunxen@gateway/tor-sasl/dunxen] has joined #bitcoin-rust 14:38 -!- dunxen [~dunxen@gateway/tor-sasl/dunxen] has quit [Ping timeout: 276 seconds] 20:26 < BlueMatt[m]> Yet another rust-bitcoin project in prod - https://techcrunch.com/2022/01/18/blocks-cash-app-adopts-lightning-network-for-free-bitcoin-payments/ 20:26 < BlueMatt[m]> LDK powering Cash's new Lightning feature. special thanks to the LDK contributors in here :) 22:22 -!- trev [~trev@user/trev] has joined #bitcoin-rust --- Log closed Wed Jan 19 00:00:34 2022