(req contract.StartTaskRunRequest)
| 2388 | } |
| 2389 | |
| 2390 | func startTaskRunFromRequest(req contract.StartTaskRunRequest) (taskpkg.StartRun, error) { |
| 2391 | startReq := taskpkg.StartRun{IdempotencyKey: strings.TrimSpace(req.IdempotencyKey)} |
| 2392 | if err := startReq.Validate("start_run"); err != nil { |
| 2393 | return taskpkg.StartRun{}, err |
| 2394 | } |
| 2395 | return startReq, nil |
| 2396 | } |
| 2397 | |
| 2398 | func attachTaskRunSessionIDFromRequest(req contract.AttachTaskRunSessionRequest) (string, error) { |
| 2399 | sessionID := strings.TrimSpace(req.SessionID) |