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

Support specification of strict on Enum type fields #7761

Merged
merged 1 commit into from Oct 8, 2023

Conversation

sydney-runkle
Copy link
Member

@sydney-runkle sydney-runkle commented Oct 6, 2023

Change Summary

Support specification of strict on Enum type fields
More broadly, this allows for the strict specification to be added to lax-or-strict schema, where it's expected but for some reason wasn't allowed to be added.

Fix #7759

Checklist

  • The pull request title is a good summary of the changes - it will be used in the changelog
  • Unit tests for the changes exist
  • Tests pass on CI
  • Documentation reflects the changes where applicable
  • My PR is ready to review, please add a comment including the phrase "please review" to assign reviewers

Selected Reviewer: @lig

@sydney-runkle
Copy link
Member Author

Please review

Copy link
Contributor

@davidhewitt davidhewitt left a comment

Choose a reason for hiding this comment

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

Fix looks good to me.

I half wonder whether there's a way that we could inspect the core_schema methods to figure out what the allowed constraints could be (but probably that's a complex algorithm which isn't great to run on startup time).

@sydney-runkle sydney-runkle merged commit 822e841 into main Oct 8, 2023
60 of 62 checks passed
@sydney-runkle sydney-runkle deleted the fix-strict-with-enum-issue branch October 8, 2023 18:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants