Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The error type is lost in oneOf #657

Closed
micronull opened this issue Nov 7, 2022 · 0 comments · Fixed by #658
Closed

The error type is lost in oneOf #657

micronull opened this issue Nov 7, 2022 · 0 comments · Fixed by #658

Comments

@micronull
Copy link
Contributor

If a field must satisfy multiple rules described using oneOf, we cannot get openapi3.SchemaError types.
The only thing we will get is a string.

components:
  schemas:
    Something:
      type: object
      properties:
        field:
          title: Some field
          oneOf:
            - title: First rule
              type: string
              minLength: 10
              maxLength: 10
            - title: Second rule
              type: string
              minLength: 15
              maxLength: 15

Get the error type errorString.

@fenollp fenollp linked a pull request Nov 7, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant