Skip to content

Add missing commas to error message for validate.FileType#374

Merged
sloria merged 3 commits intomarshmallow-code:devfrom
uncle-lv:fix-validation-info
Feb 4, 2026
Merged

Add missing commas to error message for validate.FileType#374
sloria merged 3 commits intomarshmallow-code:devfrom
uncle-lv:fix-validation-info

Conversation

@uncle-lv
Copy link
Contributor

When validating file type with a type list:

no_ext_fs = FileStorage(io.BytesIO(b"".ljust(1024)), "test")
validate.FileType([".png", ".jpg"])(no_ext_fs)

Expected error info: Not an allowed file type. Allowed file types: [.png,.jpg]
Actual error info: Not an allowed file type. Allowed file types: [.png.jpg]

The comma as separator is missing.

@sloria sloria changed the title Fix validation info Add missing commas to error message for validate.FileType Feb 4, 2026
Copy link
Member

@sloria sloria left a comment

Choose a reason for hiding this comment

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

Good catch! Thanks for the PR

@sloria sloria merged commit e51f8c8 into marshmallow-code:dev Feb 4, 2026
8 checks passed
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.

2 participants