[SOLVED] Pipeline build duration starts at 43 seconds

All pipelines seem to start with a non-zero duration however once the pipeline finishes the duration is correct.

To be more precise when the pipeline starts the clone step has a non-zero duration. After the clone step finishes its duration is set to the correct value and the next step has this non-zero duration added to it. Once the complete pipeline is finished all values are correct and this offset is nowhere to be found.

The following screenshot is from a simple “Hello World” pipeline during its execution. I cannot post the final result (which has the correct build time) as discourse only allows me to upload a single file because my account is new.

This is not a Drone bug, this indicates your computer or server clocks are out of sync. This is a common problem and can be solved by syncing your clocks using ntp.

That does indeed seem to be the problem. Our CI runs inside a VM which blocks NTP packets so I have not been able to verify this but it seems to match the offset we observe.

Am I right in the assumption that the duration of finished steps is calculated by the server and the duration of active steps is calculated client-side from a given start timestamp (which therefore suffers from the relative drift between server and client)? Just curious :smiley:

yes, this is exactly how it works :slight_smile: