This PR is to fix the wrong last step duration when job failed like shown in the screenshot.
The reason is because when job failed, Fire function did not pass in Time, and r.state.StoppedAt is by default set to 0001-01-01 08:05:43 +0805 LMT, which is later on reported to gitea by UpdateTask, which calls UpdateTaskByState to update the task.Stopped, and task.Stopped is used in FullSteps, resulting in wrong calcaulation of last step duration.
This PR is to fix the wrong last step duration when job failed like shown in the screenshot.
The reason is because when job failed, `Fire` function did not pass in Time, and `r.state.StoppedAt` is by default set to `0001-01-01 08:05:43 +0805 LMT`, which is later on reported to gitea by `UpdateTask`, which calls `UpdateTaskByState` to update the `task.Stopped`, and `task.Stopped` is used in `FullSteps`, resulting in wrong calcaulation of last step duration.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
This PR is to fix the wrong last step duration when job failed like shown in the screenshot.
The reason is because when job failed,
Firefunction did not pass in Time, andr.state.StoppedAtis by default set to0001-01-01 08:05:43 +0805 LMT, which is later on reported to gitea byUpdateTask, which callsUpdateTaskByStateto update thetask.Stopped, andtask.Stoppedis used inFullSteps, resulting in wrong calcaulation of last step duration.