MCPcopy Create free account
hub / github.com/astercloud/aster / waitForCompletion

Function waitForCompletion

cmd/aster/session.go:416–428  ·  view source on GitHub ↗

waitForCompletion waits for the agent to finish processing

(ctx context.Context, ag *agent.Agent)

Source from the content-addressed store, hash-verified

414
415// waitForCompletion waits for the agent to finish processing
416func waitForCompletion(ctx context.Context, ag *agent.Agent) {
417 for {
418 select {
419 case <-ctx.Done():
420 return
421 case <-time.After(100 * time.Millisecond):
422 status := ag.Status()
423 if status.State == types.AgentStateReady {
424 return
425 }
426 }
427 }
428}
429
430// printWelcome prints the welcome message
431func printWelcome(useColor bool, modelConfig *types.ModelConfig, recipeConfig *recipe.Recipe, workDir, sessionID string) {

Callers 1

runREPLFunction · 0.85

Calls 1

StatusMethod · 0.45

Tested by

no test coverage detected