vxcontrol/pentagi · error
temporal window search failed: %w
Error message
temporal window search failed: %w
What it means
Wrapper error returned when the Graphiti client's TemporalWindowSearch RPC/HTTP call itself fails (network error, server 5xx, timeout). The original error is preserved via %w so callers can errors.Is/As into the underlying cause. Note transport errors may be classified as soft/retryable upstream.
Source
Thrown at backend/pkg/tools/graphiti_search.go:376
}
maxResults := args.MaxResults.Int()
if maxResults <= 0 {
maxResults = DefaultTemporalMaxResults
}
req := graphiti.TemporalSearchRequest{
Query: args.Query,
GroupID: &groupID,
TimeStart: timeStart,
TimeEnd: timeEnd,
MaxResults: maxResults,
Observation: observationObject,
}
resp, err := t.graphitiClient.TemporalWindowSearch(ctx, req)
if err != nil {
return "", fmt.Errorf("temporal window search failed: %w", err)
}
return FormatGraphitiTemporalResults(resp, args.Query), nil
}
// handleEntityRelationshipsSearch finds relationships from a center node
func (t *graphitiSearchTool) handleEntityRelationshipsSearch(
ctx context.Context,
groupID string,
args GraphitiSearchAction,
observationObject *graphiti.Observation,
) (string, error) {
if args.CenterNodeUUID == "" {
return "", fmt.Errorf("center_node_uuid is required for entity_relationships search")
}
if _, err := uuid.Parse(args.CenterNodeUUID); err != nil {
return "", fmt.Errorf(
"center_node_uuid must be a valid UUID copied verbatim from the 'UUID:' field of a prior "+View on GitHub (pinned to ea665308ba)
Solutions
- Check the wrapped cause: if it is a transport/*url.Error, retry the search after a short backoff
- Verify the Graphiti service is up and reachable (docker compose ps, health endpoint)
- Inspect Graphiti server logs for a 5xx cause
- Confirm network/DNS/TLS configuration between PentAGI and Graphiti
Defensive patterns
Strategy: retry
Validate before calling
// No pre-call validation helps; ensure the service is reachable first
if err := graphitiHealthCheck(ctx); err != nil {
return fmt.Errorf("graphiti unreachable, skipping temporal search: %w", err)
} Try / catch
resp, err := client.TemporalWindowSearch(ctx, req)
if err != nil {
var urlErr *url.Error
if errors.As(err, &urlErr) {
// transient transport failure: retry with backoff
return retryWithBackoff(ctx, req)
}
return fmt.Errorf("temporal window search failed: %w", err)
} Prevention
- Monitor Graphiti service health in the compose stack
- Set sane client timeouts and retry budgets
- Alert on repeated upstream failures from the search tool
When it happens
Trigger: TemporalWindowSearch returns a non-nil error: Graphiti service down, connection refused, timeout, or a 5xx response from the API.
Common situations: Graphiti container not running or unreachable in the compose network; transient network partitions; Graphiti overloaded or restarting during heavy agent activity.
Related errors
- entity relationships search failed: %w
- failed to do request: %v
- google search failed: %w
- failed to do request: %w
- request to Sploitus failed: %w
AI-assisted analysis of vxcontrol/pentagi@ea665308ba (2026-09-01).
Data as JSON: /api/errors/42a71ff4fcd9773f.
Report an issue: GitHub.