WEL error codes

Every WEL error includes a stable code. The code remains the same when the error message changes or is translated. Use the code to search for an error, configure alerts, or include it in a support request.

_ is the input your expression receives in these examples. Refer to Input variables for more information.

FEATURE AVAILABILITY

WEL is currently available to select customers. Contact your Customer Success Representative to confirm whether it is available in your workspace.

Error codes are organized into the following categories:

CategoryRangeDescription
Parse and static analysisE001E021The expression itself is malformed. Not catchable.
Type errorsE100E107A value isn't the type an operation needs. Catchable.
Runtime errorsE200E238The data is wrong, missing, or out of range. Catchable.
Host errorsE300E303Something outside the expression failed. Mostly not catchable.

Identify the family

The error family identifies the source of the error.

  • E0xx: The expression is wrong for every input, and it can't be caught, because nothing can recover from a script that won't parse. These surface as you write the expression, not in production.

  • E1xx and E2xx: The expression itself is fine, but this particular record doesn't have the shape it expected, such as a missing field or a string where a number belongs. These are the errors most likely to surface in production, often partway through a batch that otherwise runs cleanly. They are catchable, so you can decide what should happen.

  • E3xx: The expression itself is fine, but a host function or another dependency it relies on didn't behave as expected. Catchability differs by code. E300 is catchable, because a missing optional host value is recoverable. E301E303 isn't catchable, because the host itself failed.

Catchability

The try-fallback operator |? catches a catchable error and returns a fallback instead. A non-catchable error always propagates.

text
_.customer.email |? 'unknown'
Integer(_.qty) |? 0

Compare |? and |

The distinction between |? and | matters most of all, and a mix-up here is a common source of confusion.

OperatorHandlesDoesn't handle
|A null valueAn error
|?An errorN/A

Reading a field that doesn't exist raises E104. It doesn't produce null, so | won't save you:

text
_.customer.nickname | 'none'      // still raises E104
_.customer.nickname |? 'none'     // returns 'none'

Use | when the key exists and its value may be null or blank, usually with presence, which normalizes every kind of absence to null:

text
presence(_.display_name) | 'Unknown'

Use |? when the shape itself may differ.

A FALLBACK IS A DECISION, NOT A FIX

|? 0 on a currency field means a malformed amount silently becomes zero, and the job reports success. That is sometimes right and sometimes an invoice that quietly goes out wrong.

Use a fallback when the absence is expected and the default is genuinely correct. Let the error propagate when it isn't. A failed job is visible, and a wrong number isn't.

Parse and static analysis errors

WEL raises these errors before evaluation begins. They occur for every input and aren't catchable.

CodeMessageResolution
E001Script requires a newer WEL version than the runtime supportsThe expression uses a feature this engine doesn't have. Check the engine version.
E002Unexpected tokenA syntax error. The caret (^) in the message points at the offending token.
E003Unterminated string literalA quote (' or ") isn't closed. Apostrophes use the same character as single quotes ('), so an apostrophe inside a single-quoted string closes it early.
E004Invalid number literalCheck for a stray separator or a malformed exponent.
E005Invalid binary literalA 0x"..." literal contains something other than hex digits.
E006Unexpected end of inputSomething isn't closed: a bracket ([), a parenthesis ((), or a do with no body.
E007Invalid regular expressionThe pattern doesn't compile.
E008Binary() can't contain non-ASCII charactersUse encode_string with an explicit encoding instead.
E009Variable is already definedRename the inner binding. WEL doesn't allow shadowing.
E010Undefined variableA typo, or a name used outside the let that binds it.
E011Undefined functionA typo, or a function that doesn't exist. Check the standard library.
E012Wrong number of argumentsCheck the signature on the function's reference entry.
E013Invalid locale configurationCheck the locale settings on the action.
E014Expression nesting too deepBreak the expression into let bindings.
E015Identifier too longShorten the name.
E016Invalid format specificationCheck the format string in an f-string or format function.
E017Invalid hostfx referenceCheck the host function reference syntax.
E018HostFx namespace isn't allowedThe namespace isn't permitted in this context.
E019Number literal too longReduce the digits, or read the value as a String and convert it.
E020Invalid constant for constructorThe literal doesn't fit the constructor. Duration('P1D') raises this. Duration takes clock durations such as PT24H.
E021Expression is too largeSplit the transformation across more than one step.

Type errors

WEL raises these errors when a value isn't the type an operation needs. All type errors are catchable.

WEL doesn't automatically coerce arguments to satisfy a function or operator. Convert values explicitly when their input type doesn't match the required type. Refer to Conversion functions for details.

CodeMessageResolution
E100Type mismatch: expected one type, got anotherConvert explicitly: String(...), Integer(...), Decimal(...). The most common error in WEL.
E101Operator isn't supported for these typesCheck both operands. A String plus a number raises this. Convert one of them.
E102Cannot cast one type to anotherFor example, Integer('3 items') won't convert. Clean the value first, or use |? to supply a default.
E103Mixed precision between Decimal and FloatMake both sides the same type. Make both Decimal for money. Refer to Data types for details.
E104Cannot access field on this typeThe field is missing, or the value isn't a Map. Use has_key?, or |? for a default.
E105Lambda expects a different number of argumentsCheck the lambda's parameters. filter_by on a Map passes two, not one.
E106Function expects a different number of argumentsCheck the signature.
E107Lambda can't be used as a value hereA lambda is only valid as an argument to a function that takes one.

E103 is about money

Decimal and Float won't mix. A silent mix would destroy the exactness that makes Decimal worth using. The result is approximate when a Float enters the calculation, and nothing downstream can tell.

The fix is almost always to make the other operand a Decimal rather than to convert the Decimal to a Float when you hit E103 on a total.

RECIPES ENABLE MIXED PRECISION BY DEFAULT

The Transform data action has a Mixed precision field which configures whether Decimal and Float can mix. This field defaults to allow, which means E103 doesn't raise for recipe actions unless you set the field to deny.

Runtime errors

WEL raises these errors during evaluation when an input value can't be processed. All runtime errors are catchable.

Data shape and access

The following errors occur when the data doesn't have the shape or value an operation expects:

CodeMessageResolution
E200Undefined or indeterminate arithmetic resultGuard the divisor to prevent dividing by zero or a similarly undefined operation.
E201Index out of boundsThe list is shorter than expected. Use first, last, or |?.
E202Cannot access property of nullA parent field is null. Use |? or check with present?. Also raised by an aggregate function when the Nulls in aggregates flag is off and the list contains null.
E203Guard condition failedA let ... guard rejected the input. The message names the condition.
E204one! expects exactly one elementA lookup matched zero or several records. This error is the function doing its job. Decide which case you have.
E205Cannot concatenate with nullWrap the value: presence(x) | ''.
E207Cannot compute on an empty listavg of nothing has no answer. Check the list is non-empty first.
E211Value out of rangeThe message gives the permitted range.
E217Required field is missing or blankSupply the field, or handle its absence.
E231Undefined nameThe name isn't bound at this point.
E232Invalid value: expected one of a setAn option token isn't in the allowed set. The message lists what is allowed.

Parsing and conversion

The following errors occur when a value can't be parsed as, or converted to, the expected format:

CodeMessageResolution
E206Invalid or unsupported encodingCheck the name against encodings().
E208Invalid URLThe value isn't a well-formed URL.
E209JSON parse errorThe input isn't valid JSON. The message gives the line and column.
E210JSON serialize errorThe value can't be represented in JSON.
E212Invalid date valueThe value isn't a date the parser accepts. Supply a format option.
E213Invalid duration valueCheck the ISO 8601 duration form.
E214Invalid regular expressionThe pattern was built at runtime and doesn't compile. Use escape_for_regex on interpolated values.
E215Invalid timezoneUse an IANA name such as Europe/London.
E216Ambiguous or non-existent datetimeThe datetime falls on a daylight-saving boundary. Set on_gap or on_fold to resolve the ambiguity.
E230Invalid time valueThe value isn't a time the parser accepts.
E233Invalid data for the encodingThe bytes aren't valid in the encoding named.
E234Character can't be encodedThe target encoding can't represent this character. Check first with convertible_to_encoding?.
E235Rounding required but mode is exactThe value doesn't fit the requested places. Either accept a rounding mode or treat it as bad data.

Schema and structure

The following errors occur when a value's structure doesn't match a declared schema, options map, or path expression:

CodeMessageResolution
E218Schema type mismatch on a fieldThe output doesn't match the declared Output schema.
E219Schema assertion failed on a fieldA declared constraint wasn't met.
E222Invalid map fieldAn unrecognized key in an options map, usually a typo. WEL validates options rather than ignoring them, so the typo surfaces here instead of silently changing behavior.
E223Invalid JSONPath expressionCheck the path syntax.
E224Unsupported JSONPath featureFilters, unions, and function extensions are outside the supported subset. Use deep_collect_by instead.
E229Key collisionTwo source keys produced the same output key. Last write wins. This error warns you it happened.

Limits

The following errors occur when an expression, name, literal, or the data it processes has exceeded a size limit:

CodeMessageResolution
E225Result too largeAn operation would produce more elements than the limit allows. Filter before expanding.
E226Recursion limit exceededFlatten the expression.
E227Memory limit exceededProcess the data in smaller batches.
E228Value nesting too deepThe structure is nested past the limit. Flatten the value before processing it further.

Serialization

The following errors occur when a value can't be serialized to a WEL literal:

CodeMessageResolution
E236HostFx values can't be serialized to a WEL literalResolve the value before serializing.
E237NaN can't be serialized to a WEL literalFilter it out. present? treats NaN as absent.
E238Skip inside a Map can't be serialized to a WEL literalRemove the Skip before serializing.

Other

CodeMessageResolution
E220Cryptographic operation failedThe message gives the cause. A common one is a key shorter than the algorithm requires. HS256 needs at least 32 bytes.
E221A general errorThe message carries the detail.

Host errors

WEL raises these errors outside the expression.

CodeMessageCatchableResolution
E300Unresolved hostfxYesA host value wasn't supplied. Catchable, because a missing optional value is recoverable.
E301Host function failedNoThe host itself failed, and the failure isn't recoverable inside the expression.
E302Invalid hostfx fieldNoA field in the host function configuration is invalid. Check the configuration.
E303TLV serialize errorNoThe value couldn't be serialized to the host's TLV format.

Common errors

The following errors commonly result from input that doesn't match the type or shape expected by an expression:

CodeUsually means
E100A field arrived as a String and is being used as a number, or the reverse
E104An optional field is absent from this record
E102A value won't convert: an empty string where a number was expected
E103A Decimal amount met a Float somewhere in the arithmetic

Reduce these errors by converting input fields to their expected types at the start of a transformation and handling optional values explicitly. Use presence(...) | default for fields that are genuinely optional. Refer to Conversion functions and Common functions for details.

Last updated: