MCPcopy Create free account
hub / github.com/compozy/agh / decodeTaskExecutionProfileRef

Function decodeTaskExecutionProfileRef

internal/daemon/native_profile_tools.go:99–116  ·  view source on GitHub ↗
(
	req toolspkg.CallRequest,
	scope toolspkg.Scope,
)

Source from the content-addressed store, hash-verified

97}
98
99func decodeTaskExecutionProfileRef(
100 req toolspkg.CallRequest,
101 scope toolspkg.Scope,
102) (string, taskpkg.ActorContext, error) {
103 var input taskExecutionProfileRefInput
104 if err := decodeNativeInput(req, &input); err != nil {
105 return "", taskpkg.ActorContext{}, err
106 }
107 taskID, err := requiredNativeString(req.ToolID, "task_id", input.TaskID)
108 if err != nil {
109 return "", taskpkg.ActorContext{}, err
110 }
111 actor, err := actorContextFromScope(scope)
112 if err != nil {
113 return "", taskpkg.ActorContext{}, err
114 }
115 return taskID, actor, nil
116}
117
118func (i *taskExecutionProfileInput) profile(taskID string) (taskpkg.ExecutionProfile, error) {
119 profileTaskID := strings.TrimSpace(i.TaskID)

Callers 2

Calls 3

decodeNativeInputFunction · 0.85
requiredNativeStringFunction · 0.85
actorContextFromScopeFunction · 0.85

Tested by

no test coverage detected