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

DM-40567: Diagnose group mappings to strings #838

Merged
merged 2 commits into from
Aug 30, 2023
Merged

DM-40567: Diagnose group mappings to strings #838

merged 2 commits into from
Aug 30, 2023

Conversation

rra
Copy link
Member

@rra rra commented Aug 30, 2023

Gafaelfawr previously accepted a group_mapping rule whose value was a string rather than a list of group names and interpreted it as a list of single-letter group names corresponding to the letters in the string. This configuration now produces a validation error during startup.

Do this by using proper Pydantic models to validate the value of group_mapping in the settings class and convert to strings only when building the config. This avoids a complex pre-validator that was buggy.

@rra rra enabled auto-merge August 30, 2023 19:44
Gafaelfawr previously accepted a `group_mapping` rule whose value
was a string rather than a list of group names and interpreted it
as a list of single-letter group names corresponding to the letters
in the string. This configuration now produces a validation error
during startup.

Do this by using proper Pydantic models to validate the value of
group_mapping in the settings class and convert to strings only
when building the config. This avoids a complex pre-validator that
was buggy.
@rra rra merged commit e03c4d9 into main Aug 30, 2023
6 checks passed
@rra rra deleted the tickets/DM-40567a branch August 30, 2023 21:26
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 this pull request may close these issues.

1 participant