django-rest-framework-version-transforms
django-rest-framework-version-transforms copied to clipboard
Recommendation for versioning exception handlers?
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.
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.