Type Alias: OsfqlErrorType
@kortexya/reasoninglayer / OsfqlErrorType
Type Alias: OsfqlErrorType
Section titled “Type Alias: OsfqlErrorType”OsfqlErrorType =
"parse"|"compile"|"execution"|"row_cap"|"refused"|"lock_timeout"
Defined in: src/types/osfql.ts:1002
The class of an OSFQL failure, as POST /api/v1/osfql and
POST /api/v1/osfql/preview report it in error_type.
Remarks
Section titled “Remarks”parse(HTTP 400) — the program text does not parse.compile(HTTP 400) — it parses and does not compile.execution(HTTP 422) — it failed while running, including anALTER SORTwhose subject sort is unknown. A write refusal carries OsfqlRefusal beside it. ADROP SORT/ALTER SORT … PARENTSthat fails for a reason other than a refusal answers the status of its REST route.row_cap(HTTP 422) — one candidate-set materialisation outgrew the request’smaxRows. Nothing was written. Repair it with aLIMIT, a narrower pattern, or a largermaxRows.refused(HTTP 400 / 404 / 409) — a program refused before it ran because aDROP SORT/ALTER SORT … PARENTSis not alone (OsfqlFailure.atomicRefusal, HTTP 400); anALTER SORT … PARENTSnaming an unknown or foreign parent (HTTP 400); aDROP SORTthe guarded sort delete refused (sortDeleteRefusal); or a move the engine refused.lock_timeout(HTTP 503) — other writers kept the tenant’s knowledge base locked until the request deadline, and nothing ran. OnlyPOST /api/v1/osfqlanswers it (also before a read-onlyMATCH, when the ruleset rebuild cannot get the lattice in time); the preview never does. Retry it as is, or send a largertimeoutMs.
The seventh wire value, timeout (HTTP 504), is not an OsfqlError: the
SDK throws DeadlineExceededError for it, the same class every other
route’s deadline throws.
Example
Section titled “Example”const kind: OsfqlErrorType = 'row_cap';