An exposed workflow port is named in the permitted alphabet
An exposure name is a caller-facing parameter name. Restricting it to a small alphabet keeps it usable as a key in every context a caller passes it through.
The rule
Normative: this is the rule
- A workflow exposure entry's
nameMUST match^[a-z0-9_-]+$. - A name that is absent, empty or outside that alphabet MUST be refused with
R4_NAME_FORMATatschema.{side}.{index}, where{side}isinputoroutputand{index}the entry's position in that side's list. - Unlike R4.c, this failure MUST NOT skip the entry's remaining checks: uniqueness, and the node and port checks of a bound entry, MUST still be evaluated.
- Two entries whose names are both the empty string therefore yield two
R4_NAME_FORMATerrors and oneR4_NAME_DUPLICATE. - An absent name takes part in no uniqueness comparison.
Why
Fixtures
Test cases whose outcome this rule decides. A case compares absent, null and empty members exactly; the fixtures README defines each operation. Where a case and the rule disagree, the rule is right.
Two absent names are two format errors and no duplicate validate-exposure
An absent name takes part in no uniqueness comparison. Both entries are unbound, so no node or port check runs.
{ "given": { "inputs": [ {}, {} ] }, "expect": { "errors": [ { "code": "R4_NAME_FORMAT", "at": "schema.input.0" }, { "code": "R4_NAME_FORMAT", "at": "schema.input.1" } ] } }Two empty names are two format errors and one duplicate validate-exposure
The empty string is a name like any other, so two of them repeat.
{ "given": { "inputs": [ { "name": "" }, { "name": "" } ] }, "expect": { "errors": [ { "code": "R4_NAME_FORMAT", "at": "schema.input.0" }, { "code": "R4_NAME_FORMAT", "at": "schema.input.1" }, { "code": "R4_NAME_DUPLICATE", "at": "schema.input.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 · R4.a · changed in spec 1.0