i'm doing some research about Ethereum 2.0 for university. I think i understand the way it works, but i have a perplexity about the proposer selection in a slot, especially after reading the codes here: https://github.com/ethereum/eth2.0-specs
From what i understand, at the beginning of a slot a validator check whether he's a proposer or not by using the compute_proposer_index, which takes as parameter the beacon state, a sequence of validator and the seed. In general all informations come from the beacon state: slot, epoch, randao_mixes, list of active validators...
My question is: assuming that the state change only with a block (like eth 1), if a proposer doesn't send a block during its slot, maintaining the same state, how is the next proposer selected? Shouldn't the random variables remain the same, causing the election of the same proposer over and over until he sends out a block?
Example: i'm at slot 500 and so the state is set at Slot: 500; from the informations i got in the state the next proposer should be X, but at slot 501 X goes offline and the state is unchanged: if at slot 502 i run again the code i should get X again, since nothing changed, and the blockchain gets stuck until X comes back online.
Ofc is not like this, i'm missing something, i just can't see what. Can you help me? Many thanks in advance.