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

Recommendation for versioning exception handlers? #13

Open
phillbaker opened this issue Sep 3, 2019 · 1 comment
Open

Recommendation for versioning exception handlers? #13

phillbaker opened this issue Sep 3, 2019 · 1 comment

Comments

@phillbaker
Copy link
Contributor

Similar to #12, was curious if there was a recommended way to handle exception response versioning. If a custom handler is defined:

REST_FRAMEWORK = { 
    'EXCEPTION_HANDLER': 'foo.bar.custom_exception_handler'
}

We can introspect the version in the handler, but was curious if there was a better way to approach it.

@mrhwick
Copy link
Owner

mrhwick commented Nov 15, 2019

This is a great use case I hadn't thought of when I wrote the library. I'll take a look at the custom exception handler internals and docs and see how you could do transforms for those too.

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

No branches or pull requests

2 participants