• Forum has been upgraded, all links, images, etc are as they were. Please see Official Announcements for more information

What's the deal with winners and the strings?

nmarley

Administrator
Dash Core Group
So if I run 'masternode winners', i'll get a list of blocks and it's a string, usually a comma-separated list of addresses and the number of votes, separated by colons. Example:

Code:
"366154"=>"XxNzKe73xLT8qY1UXRfcgikVbP2vwvFGyj:10",

But sometimes, it's a hash instead, e.g.:

Code:
"365552"=>"eac6392cd0d63e4b2ebd3c60da2d3e13137c892cd4cd1a8f3885077ac86b7487",

What does this mean, and how can I use that?

I wrote a system based on the first example, and it's broken now that I got to this... I have no idea what this hash is or what to do with it.

Anyone know?
 
So if I run 'masternode winners', i'll get a list of blocks and it's a string, usually a comma-separated list of addresses and the number of votes, separated by colons. Example:

Code:
"366154"=>"XxNzKe73xLT8qY1UXRfcgikVbP2vwvFGyj:10",

But sometimes, it's a hash instead, e.g.:

Code:
"365552"=>"eac6392cd0d63e4b2ebd3c60da2d3e13137c892cd4cd1a8f3885077ac86b7487",

What does this mean, and how can I use that?

I wrote a system based on the first example, and it's broken now that I got to this... I have no idea what this hash is or what to do with it.

Anyone know?

I thought 10 meant a consensus count, thats how many agree on the winner for that block right?
I have never seen what look like VIN in the winners list myself. But look at the block explorer it doesn't look like the reward was split between miner and masternode.....

https://chainz.cryptoid.info/dash/b...a6a806f46f4788552ab4fc38565f8511fc8e136a7.htm
 
Last edited by a moderator:
Yeah, 10 means consensus. It's actually just the address with the highest amount, sometimes it's a 9 or 8 or a 7.

I don't think it's a vin, because getrawtransaction doesn't return anything for that hash. This seems to have happened with blocks 365552 - 365556, then it went back to normal. I've seen it before in previous blocks also, but my process had started indexing after that, so I ignored it for those.

Yeah, I have no idea on the payout of that also, since 1176 dash are paid out to one address and 5+ to another... in the coinbase transaction. Doesn't seem like a superblock, but maybe. But then would that have happened for the next 5 transactions or so?
 
365552 was a superblock so maybe something getting re-arranged with that?

EDIT: Sry, didn't see the end of the last message, eac6392cd0d63e4b2ebd3c60da2d3e13137c892cd4cd1a8f3885077ac86b7487 was the reimbursement budget hash so I'd guess filtering addresses would give just the block reward amounts without the budget payments.
 
Last edited by a moderator:
365552 was a superblock so maybe something getting re-arranged with that?

EDIT: Sry, didn't see the end of the last message, eac6392cd0d63e4b2ebd3c60da2d3e13137c892cd4cd1a8f3885077ac86b7487 was the reimbursement budget hash so I'd guess filtering addresses would give just the block reward amounts without the budget payments.

Ok, yeah, that's exactly what those hashes are -- the hashes for the budget proposals.

Is this the only way to know if a block is a superblock -- to check the winner string if it's a hash or a list of addresses?
 
Ok, yeah, that's exactly what those hashes are -- the hashes for the budget proposals.

Is this the only way to know if a block is a superblock -- to check the winner string if it's a hash or a list of addresses?

I'm probably not the best to ask as I'm not all that familiar with the commands but it looks like the simplest option, "mnbudget nextblock" will give the next superblock so it could probably be filtered out using that but you where getting successive blocks with different info and that would only filter out that single block. There's details on checking address validity here:
http://rosettacode.org/wiki/Bitcoin/address_validation

Iirc there are much easier ways of doing it, testing the length would be a rough and ready way and it might be easier to run the output through something similar to discard the budget blocks from the output.
 
I'm probably not the best to ask as I'm not all that familiar with the commands but it looks like the simplest option, "mnbudget nextblock" will give the next superblock so it could probably be filtered out using that but you where getting successive blocks with different info and that would only filter out that single block. There's details on checking address validity here:
http://rosettacode.org/wiki/Bitcoin/address_validation

Iirc there are much easier ways of doing it, testing the length would be a rough and ready way and it might be easier to run the output through something similar to discard the budget blocks from the output.

Oh cool, I didn't know "mnbudget nextblock" existed — thanks for that.

I ended up doing this in Ruby, basically checking for length of 64 chars & no colon in the winner string:

Code:
def is_budget_payout?
  (64 == winner_string.length) && (winner_string[':'].nil?)
end
 
Back
Top