1
0
mirror of https://github.com/woodpecker-ci/woodpecker.git synced 2025-11-23 21:44:44 +02:00

Use UUID instead of step name where possible (#3136)

things I found while looking at  #3109
This commit is contained in:
6543
2024-01-09 05:43:03 +01:00
committed by GitHub
parent 31614d0e38
commit c64340cf8f
5 changed files with 15 additions and 15 deletions

View File

@@ -31,22 +31,22 @@ var (
// An ExitError reports an unsuccessful exit.
type ExitError struct {
Name string
UUID string
Code int
}
// Error returns the error message in string format.
func (e *ExitError) Error() string {
return fmt.Sprintf("%s : exit code %d", e.Name, e.Code)
return fmt.Sprintf("uuid=%s: exit code %d", e.UUID, e.Code)
}
// An OomError reports the process received an OOMKill from the kernel.
type OomError struct {
Name string
UUID string
Code int
}
// Error returns the error message in string format.
func (e *OomError) Error() string {
return fmt.Sprintf("%s : received oom kill", e.Name)
return fmt.Sprintf("uuid=%s: received oom kill", e.UUID)
}