FlowiseAI/Flowise · error · Error

Failed to search Arxiv: ${errorMessage}

Error message

Failed to search Arxiv: ${errorMessage}

What it means

Thrown as the outer catch-all of ArxivTool._call, wrapping any error that was not already re-thrown by the inner per-paper logic (error 351) or the query guard (error 350). The original errorMessage is interpolated and console.error'd. It typically wraps fetchResults failures (error 348) that propagate up, or unexpected runtime errors.

Source

Thrown at packages/components/nodes/tools/Arxiv/core.ts:263

                        if (!this.continueOnFailure) {
                            throw new Error(`Failed to process paper "${result.title}": ${errorMessage}`)
                        } else {
                            // Add error notice and continue with summary only
                            const publishedDate = result.published ? new Date(result.published).toISOString().split('T')[0] : 'Unknown'
                            const fallbackContent = `Published: ${publishedDate}\nTitle: ${result.title}\nAuthors: ${result.authors.join(
                                ', '
                            )}\nSummary: ${result.summary}\n\n[ERROR: Could not load full content - ${errorMessage}]`
                            docs.push(fallbackContent)
                        }
                    }
                }

                return docs.join('\n\n---\n\n')
            }
        } catch (error) {
            const errorMessage = error instanceof Error ? error.message : 'Unknown error'
            console.error('Arxiv search error:', errorMessage)
            throw new Error(`Failed to search Arxiv: ${errorMessage}`)
        }
    }
}

View on GitHub (pinned to abe4a8601a)

Solutions

  1. Inspect errorMessage — if it mentions an HTTP status, follow the retry guidance for error 348.
  2. If it mentions a parse error, the Arxiv response shape may have changed; update parseArxivResponse.
  3. For transient errors, retry the whole _call once after a short backoff before surfacing to the user.

Example fix

// before
} catch (error) {
  const errorMessage = error instanceof Error ? error.message : 'Unknown error'
  console.error('Arxiv search error:', errorMessage)
  throw new Error(`Failed to search Arxiv: ${errorMessage}`)
}
// after: preserve the cause for upstream diagnosis
} catch (error) {
  const cause = error instanceof Error ? error : new Error(String(error))
  throw new Error(`Failed to search Arxiv: ${cause.message}`, { cause })
}
Defensive patterns

Strategy: try-catch

Validate before calling

async function arxivPreflight(query: string) {
  if (!query || !query.trim()) throw new Error('Query is required for Arxiv search')
  // optional: probe connectivity
  const r = await fetch('https://export.arxiv.org/api/query?max_results=1&search_query=all:test')
  if (!r.ok) throw new Error(`Arxiv unreachable: ${r.status}`)
}

Try / catch

try {
  return await tool._call({ query })
} catch (e) {
  const msg = (e as Error).message
  if (/429|5\d\d|ECONN/.test(msg)) { /* backoff and retry once */ }
  else throw new Error(`Failed to search Arxiv: ${msg}`)
}

Prevention

When it happens

Trigger: fetchResults throws (Arxiv API non-2xx, network error); parseArxivResponse throws on malformed XML; an unexpected TypeError during result mapping; an uncaught error from the no-full-content path.

Common situations: Arxiv API outage or rate limit during the search step; upstream XML schema change in the Arxiv response that breaks the parser; transient network failure.

Related errors


AI-assisted analysis of FlowiseAI/Flowise@abe4a8601a (2026-08-12). Data as JSON: /api/errors/973e1da3441a4bdc. Report an issue: GitHub.