Skip to content

Add Support for marshmallow.fields.Enum in marshmallow ≥ v3.18#170

Open
hf-kklein wants to merge 1 commit intofuhrysteve:masterfrom
hf-kklein:marshmallow_native_enum
Open

Add Support for marshmallow.fields.Enum in marshmallow ≥ v3.18#170
hf-kklein wants to merge 1 commit intofuhrysteve:masterfrom
hf-kklein:marshmallow_native_enum

Conversation

@hf-kklein
Copy link
Contributor

This fixes #169.

Detailed changes:

  • Introduce distinction between Enums imports from marshmallow_enum and marshmallow.fields (the latter are refered to as "marshmallow native" Enums)
  • Add function to find out if the version of marshmallow used supports the native Enum type
  • Add test cases that reproduce the issue
  • Adapt the code to also support the native enums

@hf-kklein hf-kklein marked this pull request as ready for review October 9, 2022 19:16
@hf-kklein hf-kklein changed the title Add Support for marshmallow.fields.Enum in marshmallow >= v3.18 Add Support for marshmallow.fields.Enum in marshmallow ≥ v3.18 Oct 9, 2022
This fixes fuhrysteve#169.

Detailed changes:
* Introduce distinction between Enums imports from `marshmallow_enum` and `marshmallow.fields` (the latter are refered to as "marshmallow native" Enums)
* Add function to find out if the version of marshmallow used supports the native Enum type
* Add test cases that reproduce the issue
* Adapt the code to also support the native enums
@imcdo
Copy link

imcdo commented Sep 27, 2024

@hf-kklein any chance this gets merged?

@hf-kklein
Copy link
Contributor Author

@imcdo Sorry, I just opened the PR, I'm not the maintainer. But after 4 years... I wouldn't rely on it ;)

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.

marshmallow-jsonschema is not compatible with marshmallow.fields.Enum added in marshmallow v3.18.0

2 participants