-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Remove app instance from Config for error handler setting #2320
Conversation
Code Climate has analyzed commit 918b06f and detected 0 issues on this pull request. The test coverage on the diff in this pull request is 86.6% (86% is the threshold). This pull request will bring the total coverage in the repository to 86.8% (0.0% change). View more on Code Climate. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for making this change
This reverts commit 45e812f.
…rg/sanic into decouple-config-errorhandler-app
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM except the DescriptorMeta
in the Config
class, because I don't understand what it does 😅
It stores an internal reference to descriptors so that when setting a value we determine if we need to execute the setter or fallback to the dict update. |
This stems from a conversation with @prryplatypus and @ashleysommer re: the change to get the ErrorHandler functioning as expected in v21.9. This unfortunately introduced
app
as a property of the Config object.This PR removes that, reverting back to the previous methodology, but still retaining the as expected ability to apply changes to the
Config
post-instantiation and carry through to the route handler that was missing in earlier v21.TODO
Config
whereErrorHandler
is not defaultfallback