FlowDrop Workflow Specification 1.0-draft

An empty expression is not an error

The rule

Normative: this is the rule
  1. An empty expression is valid: it passes validation, and it produces a defined result rather than a failure.
  2. A mapper output whose expression is empty is null, whatever the engine.
  3. An extractor whose path is empty returns its input unchanged, reports success, and reports no match.

What it means

An empty expression is not treated as an author mistake in either direction a node can use one. What "empty" resolves to is fixed by which of the two families (LANG-1) the node belongs to, not by the engine selected: a node that writes an output from an expression gets null for an empty one, and a node that reads a value out of a context by path returns that context unchanged, still reporting success, when the path is empty. Neither shape depends on which engine is configured — the short-circuit happens before an engine ever runs.

Example

A mapping node produces one output whose expression is empty:

The value of a mapper output whose expression is emptynull
null

An extractor given a path of "" against an input of {"a": 1} never reaches an engine either. It reports success, reports no match, and delivers the context it was handed back unchanged:

The data an extractor with an empty path deliversunchanged
{"a": 1}
Rule identifiers are permanent and are never renumbered. Each implementation publishes its own standing against these rules; this specification does not.spec 1.0-draft · LANG-3 · changed in spec 1.0