No because the block would either get rejected or dropped and the block reward is part of the block, so it would also be removed.
There can only be 1 block on 1 particular blockheight. 2 competing valid blocks on the same blockheight results in an accidental fork where only 1 will survive. when the next miner mines a new block, it will be mined on 1 of those 2 versions. Wich will make 1 version (chain) longer than the other.
Hahahaha I just needed to get a bit further in the course before I got my answer. Thanks!
if a node created blocks and the blocks became obsolete does this node get the reward anyway or lose the pow reward?
The reward is actually a special kind of tx called a coinbase. So when the block is dropped it also gets dropped.
Hi Tamase, I believe the issue was that the instructor was not exactly clear by what he meant. By âlose your moneyâ I think he was referring to the person who mined the block that would become stale. In that minerâs version of the blockchain they received the rewards for block height 5 but since that block is no longer valid that person lost their rewards.
On the quiz I got a question wrong and Iâm dont quite understand the difference between the two. I also thought two miners mine the same block height and then its propagated to different nodes that now have two forks. I think Im close, but dont quite understand.
Question:
How does accidental forks happen?
Correct Answer:
Different miners find a block at the same block height at the same time.
My Answer:
Miners mine the same block at the same block height but with different contents
Because the blocks are not the same if that were the case there wouldnât be any issues.
The blocks that are found are both valid, but different. If anything else they will contain a different coinbase transaction and thus have a different hash.
I did not understand the accidental fork blocks?
can you give me an example about 2 blocks that have 2 different consensus rules (the case of update forks) because I find a bit ambiguous?
I havenât seen a lecture on the rules yet, so my question is if these rules cause forking, then why are they allowed? Why would you need to change a rule in the first place?
thx
Iâm not sure what you want to know. Accidental forks and either soft or hard forks are different things. If you want to see two blocks with different rules, segwit was updated on block 477,120 and on block before that was working by old rules or BCH hard fork that occurred in block 478558.
Accidental forks occur because of physical constraints and distances between nodes. They are rare but once they occur they must be resolved. This is done by miners continuing to mine on both chains and gets resolved once more PoW is done on either of them. At that point the shorter chain gets dropped.
Its the beauty of open source. Everyone can fork the software and do their own things if they think the path the upstream choose is not optimal. Making others to follow the new rules is another story.
Another reason why you want to be able to update the rules is in case some important part of the consensus algorithm gets broken, like for example SHA256. In that case it will be necessary to fork to a new algo because the security will be compromised.
makes perfect sense.
Thanks!
I need some clarification on what happens to the transactions in a stale block once they are returned to the mempool.
They go back to the mempool, if they are not also present in the other block that didnât go dropped, and need to be remined again.
That means the miner or the stale block has lost money because he has consumed alot of electricity on that block. Is this correct?
I donât think so. Its all part of game theory. Miners compete with each other constantly to get their block accepted into the blockchain. In case of two blocks being found at the same time the race continues to get either of them accepted. The winner takes it all.
Yes, if your block becomes a stale block, you donât get the reward. Thatâs why the blockreward is unspendable for 100 blocks to make sure that the miner of a stale block doesnât already spend his block reward.
But this is merely for big mining operations like mining pools. Many people help mining in a mining pool and collectively search for the right nonce to have a valid blockhash below target of the poolâs candidate block. The money of the block reward gets splits among the miners in that pool. (in proportion of their hash rate)
Filip,
In the case of an accidental fork, the two blocks will probably contain some txs in common. When the stale blocks is discarded, its txs are returned to the mempool. What happens if some are the same as the txs in the accepted block. What prevents them from being forged into a new block?
Gaelaxy
Filip,
Following on with my last question, what prevents duplicate transactions from showing up on the both arms of a hard fork caused by an update?
Gaelaxy