Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Runtime error codes

Failures on the ox runtime serve /v1 HTTP surface (Serving surface) carry a stable error.code string in the ARGON_RUNTIME_* family. This is the published failure reference an integrator switches on. Every 4xx/5xx response — including routing, method, and request-body parse failures — uses the same envelope, so a client can key on error.code uniformly:

{
  "error": { "code": "ARGON_RUNTIME_VALIDATION_FAILED", "message": "…", "details": { … } },
  "requestId": "…",
  "moduleHash": "…"
}

These are runtime codes — distinct from the compile-time OE#### catalog of Appendix C, which are build-time diagnostics. Runtime codes are an API contract surfaced at request time.

The set below is checked against the runtime’s canonical registry (RUNTIME_ERROR_CODES in oxc-serve): a drift test in oxc-serve fails if a code is emitted without a row here, or a row names a code the runtime does not emit. Do not hand-add a row without the matching registry entry.

CodeHTTPMeaning
ARGON_RUNTIME_VALIDATION_FAILED400Argument coercion, entity-reference validation, or a malformed / wrong-content-type request body failed.
ARGON_RUNTIME_SIGNATURE_MISMATCH400Descriptor arguments do not match the declared pub callable’s parameters.
ARGON_RUNTIME_MISSING_CONTEXT400A required context field (e.g. tenantId) was absent from headers and body.
ARGON_RUNTIME_FORK_CONFLICT400The x-fork-id header and the request/path fork disagree.
ARGON_RUNTIME_INVALID_CURSOR400A pagination cursor was not issued by this server — pass back nextCursor verbatim or omit it.
ARGON_RUNTIME_UNSUPPORTED_QUERY_BODY400The declared query’s body uses a construct the served evaluator does not yet support.
ARGON_RUNTIME_UNSUPPORTED_QUERY_RESULT400The query’s result shape cannot be rendered on the wire.
ARGON_RUNTIME_UNSUPPORTED_MUTATION_RESULT400The mutation’s result shape cannot be rendered on the wire.
ARGON_RUNTIME_DERIVE_FAILED400A derive / projection evaluation failed for the named rule.
ARGON_RUNTIME_EXPLAIN_FAILED400RFD 0046 D3: reconstructing the per-fact proof tree failed for the named relation (e.g. the relation could not be resolved or the materialization erred).
ARGON_RUNTIME_EXPLAIN_BAD_TUPLE400RFD 0046 D3: an element of the explain request’s tuple is not a valid wire value.
ARGON_RUNTIME_CHECK_VIOLATION400An RFD 0025 delta-guard rejection: the mutation would create a blocking check violation. Atomic — nothing persisted; error.details.diagnostics lists the firings.
ARGON_RUNTIME_ADHOC_TYPE_ERROR400An ad-hoc query/mutation body failed to type-check against the loaded module’s schema; error.details.diagnostics lists the firings. The body is never run.
ARGON_RUNTIME_ADHOC_PREPARATION_FAILED400An ad-hoc query/mutation source could not be parsed/lowered to an executable form (malformed source, no query/derive/mutate item, or a lowering refusal).
ARGON_RUNTIME_FORK_NOT_DERIVED400A fork operation needs a prior derive that has not run.
ARGON_RUNTIME_METHOD_NOT_ALLOWED405The path exists but does not support the request method.
ARGON_RUNTIME_CAPABILITY_DENIED403The request needs a runtime capability (e.g. fork, forget) the caller/server does not grant.
ARGON_RUNTIME_ADHOC_DISABLED403The ad-hoc query/mutation surface is disabled on this deployment (RFD 0033): it is restricted to its declared invocables.
ARGON_RUNTIME_UNKNOWN_ROUTE404No route matches the request path.
ARGON_RUNTIME_UNKNOWN_QUERY404No declared pub query matches the descriptor’s qualified path.
ARGON_RUNTIME_UNKNOWN_MUTATION404No declared pub mutate matches the descriptor’s qualified path.
ARGON_RUNTIME_UNKNOWN_COMPUTE404No supported pure pub fn matches the compute descriptor’s qualified path.
ARGON_RUNTIME_UNKNOWN_CHECK404The /v1/checks check filter names no check in the module.
ARGON_RUNTIME_FORK_NOT_FOUND404The named fork does not exist in this scope.
ARGON_RUNTIME_REQUEST_TIMEOUT408The request (or the synchronous reasoner) exceeded its wall-clock budget and was abandoned before persisting.
ARGON_RUNTIME_FORK_CLOSED409The fork has been promoted or aborted and is no longer writable.
ARGON_RUNTIME_SCOPE_ID_COLLISION409Two distinct scopes hash to the same scope id (a configuration fault).
ARGON_RUNTIME_SCHEMA_MISMATCH409An artifact’s schema identity does not match the scope’s recorded identity (R-B7); set ARGON_ACCEPT_SCHEMA_CHANGE=1 to override.
ARGON_RUNTIME_MODULE_INCOMPATIBLE409A hot-reload candidate is incompatible with live ABox state (removed / changed declarations).
ARGON_RUNTIME_ADHOC_MULTI_MODULE_UNSUPPORTED409An ad-hoc query/mutation was submitted against a composed/multi-module artifact (declarations span more than one module prefix); a bare body predicate has no single prefix to re-qualify against. A tracked follow-on (RFD 0033, open questions).
ARGON_RUNTIME_RESULT_TOO_LARGE413An un-paged read exceeded the result-row cap; narrow the request or page it (page / ?limit).
ARGON_RUNTIME_REQUEST_TOO_LARGE413The request body exceeded the server’s body-size limit (default 4 MiB).
ARGON_RUNTIME_CHECK_EVAL_FAILED500A check could not be evaluated (a server / artifact fault, not a client error).
ARGON_RUNTIME_STORAGE_ERROR500The storage backend returned an error during the operation.
ARGON_RUNTIME_MODULE_NOT_LOADED503No module is currently loaded (a failed load left the prior module active or none present).
ARGON_RUNTIME_STORAGE_UNREACHABLE503/readyz / /v1/health: the storage backend is not reachable.

A batch-step failure (POST /v1/batch) rides the same envelope under the step’s own code, with the failing step’s 0-based index added at error.details.batchStep. A 429/load-shedding code is not part of the current surface (the request-timeout and result-row caps are the back-pressure mechanisms).