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

fix: validate min constraint values in openapi #4179

Merged
merged 2 commits into from
Jul 7, 2023

Conversation

kwasniew
Copy link
Contributor

@kwasniew kwasniew commented Jul 7, 2023

About the changes

Screenshot 2023-07-07 at 11 32 45

Previously constraint values were validated inside the feature toggle service not in the openapi. What it means is that change requests that are using the same schema, don't get a validation since it's inside the feature service. So I'm moving the validation of values min length to the openapi schema. Since this field is optional the validation only kicks in when values are provided, not when single value is provided.

Solves: https://linear.app/unleash/issue/1-1095/cr-allows-0-values-for-constraints

Important files

Discussion points

@vercel
Copy link

vercel bot commented Jul 7, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
unleash-monorepo-frontend ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 7, 2023 9:50am
1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
unleash-docs ⬜️ Ignored (Inspect) Jul 7, 2023 9:50am

Copy link
Contributor

@thomasheartman thomasheartman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me! Because this has always been the intended use case, then I think it's a great change to move forward with 🙌🏼

@kwasniew kwasniew merged commit 2398140 into main Jul 7, 2023
15 of 16 checks passed
@kwasniew kwasniew deleted the validate-min-constraint-values branch July 7, 2023 10:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

2 participants