-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Description
The light clients can be in 3 state at all times:
- Active
- Expired
- Frozen
The light client is only usable at the Active
state. And this status matters the most for the update_client
function because we definitely don't want to add a new state to a frozen or expired client.
Currently, if the client is frozen, we write it under ClientState
of the corresponding client. And if its expired, we don't commit it at all since it is calculated dynamically at the time where the GetStatus
query is called. We want to create a commitment for the clients where we commit the status as well. This is going to be very useful for the state lens clients since they will need to guarantee that the client is not frozen.
Right after a call to the misbehaviour
, update_client
, and right after the execution of migrate_state
, we should query the status of the client and commit it since these are the only entrypoints where we might have a state change.