Synchronize go job struct with schema

This commit is contained in:
Jan Eitzinger
2023-03-29 06:46:33 +02:00
parent 9aa12c6edc
commit 5d535edb48
8 changed files with 56 additions and 46 deletions

View File

@@ -351,7 +351,7 @@ func SanityChecks(job *schema.BaseJob) error {
if len(job.Resources) == 0 || len(job.User) == 0 {
return fmt.Errorf("'resources' and 'user' should not be empty")
}
if job.NumAcc < 0 || job.NumHWThreads < 0 || job.NumNodes < 1 {
if *job.NumAcc < 0 || *job.NumHWThreads < 0 || job.NumNodes < 1 {
return fmt.Errorf("'numNodes', 'numAcc' or 'numHWThreads' invalid")
}
if len(job.Resources) != int(job.NumNodes) {