Skip to content

Commit

Permalink
Fix command check
Browse files Browse the repository at this point in the history
Signed-off-by: 林联辉 <[email protected]>
  • Loading branch information
林联辉 committed Oct 31, 2024
1 parent f5066f1 commit 9dc8b00
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkg/argsbuilder/serving_distributed.go
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,10 @@ func (s *DistributedServingArgsBuilder) check() error {
if s.args.MasterCommand != "" || s.args.WorkerCommand != "" {
return fmt.Errorf("--command and --master-command/--worker-command can not be set at the same time")
}
} else {
if s.args.MasterCommand == "" || s.args.WorkerCommand == "" {
return fmt.Errorf("--command or --master-command/--worker-command must be set")
}
}
if s.args.MasterGPUCount < 0 || s.args.WorkerGPUCount < 0 {
return fmt.Errorf("--master-gpus/--worker-gpus is invalid")
Expand Down

0 comments on commit 9dc8b00

Please sign in to comment.