Skip to content

patternProperties value-schema validation and deep $ref map-value validation #139

@benjamineckstein

Description

@benjamineckstein

Problem

Two related map-value gaps:

  1. patternProperties values are never validated. Keys matching a patternProperties regex are admitted under closed-object enforcement (the false-rejection bug patternProperties combined with default additionalProperties:false enforcement false-rejects valid keys #65 is fixed), but the VALUE schema attached to each pattern is never translated into rules. A value of the wrong type/shape under a matching key passes.
  2. $ref-valued additionalProperties map values are not deep-validated or cast. When additionalProperties is a $ref to a component, the map values are admitted as a typed map but the referenced schema's rules are not applied to each value, and the values are not hydrated/cast into the referenced Data class. (Touches the same area as the no-op noted in Document validation no-ops: hostname/byte/binary/password formats, map-of-$ref values, scalar-union rules #18.)

Impact

Spec-invalid map values pass validation, and $ref map values are not cast to their Data type, so consumers get untyped/unvalidated payloads where the spec promised a structured, validated shape. Correctness gap.

What correct support looks like

Current behavior (recorded in fidelity report)

Both gaps are recorded in openapi-laravel.unsupported.json (the drift-checked fidelity report): patternProperties value schemas and deep $ref map-value validation/casting are listed as correctness-affecting constructs not yet faithfully represented. Related closed issues: #65 (key false-rejection, fixed), #18 (map-of-$ref no-op).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestpost-1.0Explicitly deferred past 1.0.0

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions