--- Log opened Wed Apr 01 00:00:40 2020 06:40 < adiabat> kcalvinalvin: hey is PR #106 mergable? I'd like to merge before changing everything around in cmd/ 06:42 < kcalvinalvin> adiabat yes 06:42 < adiabat> ok cool will test it out & merge 06:42 < kcalvinalvin> oh wait wait 06:42 < adiabat> (in like an hour or two) 06:42 < kcalvinalvin> maybe it un-does the fix 06:42 < kcalvinalvin> let me rebase 06:43 < adiabat> ok sure no rush 06:57 < kcalvinalvin> ok I made a new PR 06:57 < kcalvinalvin> #107 is the one to merge 09:10 < adiabat> ok will check that one 19:54 < adiabat> Hey - started using the rev.go code and there are some problems 19:55 < adiabat> I'm looking at it and will push to a WIP PR if you want to take a look as you are probably more familiar with this weird format 19:55 < adiabat> also genproofs seems to be height off by 1 20:21 < kcalvinalvin> adiabat right the genproofs height+1 20:22 < kcalvinalvin> About that... remember when the whole cmd was with text 20:22 < kcalvinalvin> The code skipped genesis but it was fine because it was just parsing a txt file 20:23 < kcalvinalvin> But I just carried over the logic and so the offsetdata *doesn't* store the offset for the genesis block 20:23 < kcalvinalvin> so if you ask for block 0, it'll give you block 1 20:24 < kcalvinalvin> So if you fetch from the files you need to do -1 of actual height 20:25 < kcalvinalvin> Yeah I did put this in comments somewhere but I guess I was the only one that knew about it 20:25 < kcalvinalvin> I'll take a look at rev.go 20:27 < kcalvinalvin> If you look at places in genproofs, you'll see "height +1" a lot. That's because the fetched block's height is -1 of the actual height 20:32 < adiabat> ok the off by 1 thing is whatever 20:33 < adiabat> can fix I guess, but the real issue is rev is... I have no idea what it's doing 20:33 < adiabat> like there's rev data, but it seems to have little or nothing to do with the txins in the block 20:34 < adiabat> like on block 962 20:35 < adiabat> whether +1 or -1, nothing around 962 has any transactions at all 20:36 < adiabat> but the rev data for 962 has 35 rev txs 20:36 < adiabat> and they're utxos from, like, block 118015, what the heck 20:36 < adiabat> this is coming from rev00000.dat 20:37 < adiabat> so why is a utxo from block 118015 in the first rev file argh 20:41 < kcalvinalvin> hmmmm... 20:41 < kcalvinalvin> I'll give it a looksie 20:42 < kcalvinalvin> Maybe I'm deserializing it wrong 20:42 < adiabat> maybe it's not *that* crazy in that blk00000.dat goes up to that height 20:42 < adiabat> so there could be rev data from that in there 20:42 < kcalvinalvin> The Blocks should be right because the magicbytes woudl fail 20:42 < adiabat> but maybe the rev stuff is in a totally different order 20:43 < kcalvinalvin> *magicbytes checking* 20:43 < adiabat> blocks are right, yeah, that's been working for a while 20:43 < adiabat> this is the first time we've actually trying *using* rev data thought right? 20:43 < kcalvinalvin> yes 20:43 < adiabat> and the whole time we're like .. hopefully it's in the same order as the blocks 20:43 < adiabat> because it'd be crazy for it not to be.... right....??? 20:44 < adiabat> but... 20:44 < kcalvinalvin> Well sipa did say that the only way it could be wrong is if you've had an orphaned block or something 20:44 < kcalvinalvin> or a reorg 20:44 < adiabat> maybe, but like 20:45 < adiabat> its not a little off, it's way off 20:45 < adiabat> ?ERROR? block 962 0 inputs but 35 revs 20:45 < adiabat> and the revs are all these utxos from the end of blk00000.dat 20:45 < adiabat> like almost the exact end 20:46 < adiabat> also I should not use mainnet data because it's super depressing, every utxo is worth like millions of dollars 20:47 < adiabat> anyway I will be up a little longer but will go to bed somewhat soon, and I'm guessing I will not figure it out by then heh :) 20:47 < kcalvinalvin> lol 20:47 < adiabat> so if you want to look at it, cool; I'll try figuring it out tomorrow as well 20:48 < adiabat> like I'm pretty sure the rev data is what we think it is 20:48 < adiabat> because sometimes it's right. or close 20:48 < kcalvinalvin> what do you mean close 20:48 < adiabat> but the rev block you get like, txs, and then txins, but why? why not just a slice of txins... why organize them into txs... 20:48 < kcalvinalvin> like an extra tx is in there? 20:49 < adiabat> also the rev data doesn't have outpoints, which, OK fine it'd be redundant 20:50 < adiabat> but that means I have to figure out what the utxos are without the outpoints which is tricky 20:50 < adiabat> also sometimes the pubkey is blank which 20:50 < adiabat> well... also sometimes the pubkey is blank in the actual output so what's that about... 20:50 < adiabat> or... no wait it's not, the block explorer just says it's blank but it's not 20:51 < adiabat> anyway 20:51 < kcalvinalvin> > but the rev block you get like, txs, and then txins, but why? oh that's how Core used to do it. I could change it 20:51 < kcalvinalvin> Now they just use the Coin class 20:52 < adiabat> do the rev txs mean they correspond to which tx is spending them 20:52 < adiabat> err 20:52 < adiabat> what I mean is, if a bunch of txins are grouped into a single rev tx, that's not because those utxos were created at the same time 20:52 < adiabat> it's because they all get spent at the same time, right? 20:52 < adiabat> yeah because they have different heights 20:54 < kcalvinalvin> Yeah it's because they're spent 20:56 < adiabat> ok the rev stuff is... somewhat coherent in that like, I get a rev block 20:57 < adiabat> and it works, but it's the rev data for block 119965 20:57 < adiabat> hmmm 20:57 < adiabat> and the lastIndexOffsetHeight is 119964 20:58 < adiabat> so... something weird is going on, like rev is counting down backwards or something, that can't be a coincidence 20:59 < adiabat> hmm yeah something switched or backwards; the last block we're going to process is the first rev block we get. 21:00 < adiabat> except not exactly first, there are a couple before that, but they have blank pubkeys 21:01 < kcalvinalvin> yeah.. ok I kinda see what you're saying 21:02 < kcalvinalvin> I'll look at it and maybe push a PR today 21:02 < adiabat> ok if not I'll look at it tomorrow 21:03 < adiabat> close though! if the rev stuff works, then genAddDel is done-ish 21:03 < adiabat> and with no extra database thankfully 21:03 < kcalvinalvin> yay 21:04 < kcalvinalvin> ⊂(◉‿◉)つ --- Log closed Thu Apr 02 00:00:41 2020