(req apicontract.StartTaskRunRequest)
| 761 | } |
| 762 | |
| 763 | func startTaskRunFromRequest(req apicontract.StartTaskRunRequest) (taskpkg.StartRun, error) { |
| 764 | startReq := taskpkg.StartRun{IdempotencyKey: strings.TrimSpace(req.IdempotencyKey)} |
| 765 | if err := startReq.Validate("start_run"); err != nil { |
| 766 | return taskpkg.StartRun{}, invalidParamsRPCError(err) |
| 767 | } |
| 768 | return startReq, nil |
| 769 | } |
| 770 | |
| 771 | func attachTaskRunSessionIDFromRequest(req apicontract.AttachTaskRunSessionRequest) (string, error) { |
| 772 | sessionID := strings.TrimSpace(req.SessionID) |
no test coverage detected