-
Notifications
You must be signed in to change notification settings - Fork 129
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Runtime error Timestamp slot must match CurrentSlot
while producing block
#2634
Comments
Running two nodes: one substrate node with the following log flags: After the Gossamer bob node connects to substrate alice it is possible to see that Alice successfully claimed the slot number
On the gossamer side when it connects with the substrate it is possible to see gossamer syncing block number one and setting the first slot as
After that gossamer starts the epoch 0 and set up all the slots:
And right after setting up the slots gossamer logs the line that says
At the same time in the substrate node, after the substrate produces block 1 and starts epoch 0 it disconnects from gossamer, but gossamer keeps producing blocks
|
The error was caused by a slight difference between the timestamp defined when the epoch starts and the timestamp inserted in the inherent when the block is built, there is a table below that describes the timestamp when the slot number was defined and the timestamp when the block is built in the slot.
For almost all slots the timestamp defined in the epoch start and the timestamp stored in the block inherent in the build process are compatible but on slot We should guarantee that we only build a block right after the start timestamp for the current slot is reached |
Timestamp slot must match CurrentSlot
while producing block
For the record, this is due to the timer triggering before the target slot Note sure if this is an OS or kernel or Go issue, but we ended up just adding an if check with an extra sleep if it happens. |
Describe the bug
I noticed that running gossamer as Alice (babe-lead: true) and two other substrate nodes as Bob and Charlie this error rarely appears.
Obs: In fact gossamer waits for the first block to be produced to initiate the epoch and set up the slots.
The text was updated successfully, but these errors were encountered: