FlowiseAI/Flowise · error · Error

${e}

Error message

${e}

What it means

Upstash's `add` path wraps failures from `UpstashVectorStore.fromDocuments` (or the index upsert with recordManager cleanup) into `new Error(e)`. The underlying cause is typically invalid `UPSTASH_VECTOR_REST_URL`/`UPSTASH_VECTOR_REST_TOKEN`, vector dimension mismatch with the Upstash index, or network failure. The re-wrap discards the original stack.

Source

Thrown at packages/components/nodes/vectorstores/Upstash/Upstash.ts:163

                    await recordManager.createSchema()
                    const res = await index({
                        docsSource: finalDocs,
                        recordManager,
                        vectorStore,
                        options: {
                            cleanup: recordManager?.cleanup,
                            sourceIdKey: recordManager?.sourceIdKey ?? 'source',
                            vectorStoreName: UPSTASH_VECTOR_REST_URL
                        }
                    })

                    return res
                } else {
                    await UpstashVectorStore.fromDocuments(finalDocs, embeddings, obj)
                    return { numAdded: finalDocs.length, addedDocs: finalDocs }
                }
            } catch (e) {
                throw new Error(e)
            }
        },
        async delete(nodeData: INodeData, ids: string[], options: ICommonObject): Promise<void> {
            const embeddings = nodeData.inputs?.embeddings as Embeddings
            const recordManager = nodeData.inputs?.recordManager

            const credentialData = await getCredentialData(nodeData.credential ?? '', options)
            const UPSTASH_VECTOR_REST_URL = getCredentialParam('UPSTASH_VECTOR_REST_URL', credentialData, nodeData)
            const UPSTASH_VECTOR_REST_TOKEN = getCredentialParam('UPSTASH_VECTOR_REST_TOKEN', credentialData, nodeData)

            const upstashIndex = new UpstashIndex({
                url: UPSTASH_VECTOR_REST_URL,
                token: UPSTASH_VECTOR_REST_TOKEN
            })

            const obj = {
                index: upstashIndex
            }

View on GitHub (pinned to abe4a8601a)

Solutions

  1. Confirm `UPSTASH_VECTOR_REST_URL` and `UPSTASH_VECTOR_REST_TOKEN` resolve and are valid.
  2. Match the embedding model dimension to the Upstash index dimension.
  3. Verify the Upstash index exists and is reachable.
  4. If using recordManager cleanup, ensure its store is reachable.

Example fix

// before
catch (e) { throw new Error(e) }

// after
catch (e) { throw new Error(`Upstash add failed: ${e instanceof Error ? e.message : String(e)}`, { cause: e }) }
Defensive patterns

Strategy: try-catch

Validate before calling

function validateUpstashAddInputs(creds: any, inputs: any) {
  if (!creds?.UPSTASH_VECTOR_REST_URL) throw new Error('UPSTASH_VECTOR_REST_URL required')
  if (!creds?.UPSTASH_VECTOR_REST_TOKEN) throw new Error('UPSTASH_VECTOR_REST_TOKEN required')
  if (!inputs?.embeddings) throw new Error('embeddings required')
}

Type guard

null

Try / catch

try { await UpstashVectorStore.fromDocuments(finalDocs, embeddings, obj) }
catch (e) { throw new Error(`Upstash ingest failed: ${e instanceof Error ? e.message : String(e)}`, { cause: e }) }

Prevention

When it happens

Trigger: Wrong/missing Upstash REST URL or token; embedding dimension != Upstash index dimension; Upstash index deleted or not created; recordManager cleanup failure; network egress blocked.

Common situations: Credentials not set or rotated; embedding model changed dimension; Upstash free-tier rate limit; URL typo (missing https); token copied with whitespace.

Related errors


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