Skip to content

Return None from path_helper when view is None - #227

Open
Fire162 wants to merge 1 commit into
marshmallow-code:mainfrom
Fire162:return-none-when-view-is-none
Open

Fire162 wants to merge 1 commit into
marshmallow-code:mainfrom
Fire162:return-none-when-view-is-none

Conversation

@Fire162

@Fire162 Fire162 commented Oct 26, 2026

Copy link
Copy Markdown

When spec.path() is called without a view (such as when manually documenting a path or using multiple plugins), path_helper previously triggered an AssertionError. Returning None allows apispec to proceed rather than crash.

Fixes #133.

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.

Flask plugin does not gracefully fail when view is None

1 participant