Skip to content

The type of properties is not validated #234

@david-caro

Description

@david-caro

Not sure if this is an issue or not, but at least I did not expect it :)

Having for example a schema like:

---
openapi: "3.1.0"
info:
  title: "Test properties types"
  version: "0.0.0"
paths:
  /some/{someparam}:
    get:
      parameters:
        - name: someparam
          in: path
          required: true
          schema:
            type: idontexistasatype

Passes the validation:

dcaro@acme$ openapi-spec-validator test.yaml 
test.yaml: OK

Currently using the latest commit from this repo:

dcaro@acme$ pip freeze | grep openapi-spec-validator
openapi-spec-validator @ git+https://github.com/python-openapi/openapi-spec-validator@118ad6125b35df075ed78d61f4f90d6a0abc1c88

I was expecting it to fail saying that the type idontexistasatype is not valid.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions