-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Drop kwargs from Application ctor #243
Comments
ok |
Please pay attention: we have used wrong code even in own tests without any error reports. |
OK for me. BTW, do you see an issue to use app.ah_container instead of app['ah_container'] ? |
@GMLudo sorry, no. Please provide a link |
@GMLudo if you are talking about hypothetical problem on processing Application keys as attributes also via |
@asvetlov: Don't worry about that, I also dislike to have values accessible via attributes, because you can't use some characters like - where with a dict, it's freedom. |
@GMLudo Yes, sure. But On
I've found the design the very useful and very important. You can find a lot of libs which breaks the rule of thumb but please don't add your own into the list without the strict reason. On development of your application (not a generic library) you are free -- use the inheritance without any restrictions: your code will show the way to keep it simple. |
Ok, thanks a lot about tips, especially about Guido tip. |
Sorry, I cannot recall the topic (not talking about the exact email asyncio was discussed in python-dev, python-ideas and tulip, you can dig Personally I've heard the rule from Guido when we worked on tulip together BTW he called Nikolay Kim "the crazy Russian" -- at winter 2013 tulip has On Thu, Jan 15, 2015 at 12:42 AM, Ludovic Gasc [email protected]
Thanks, |
I propose to just remove
**kwargs
fromApplication.__init__
signature.The problem is: we are likely want to add new parameters to the constructor in future.
But they are will clash with params used by customers, sure (we both will use simple and short parameter names).
To avoid the problem I would like to just forbid the case.
Application is not a dict in our philosophy, it's just a
MutableMapping
.If you need to store extra data in the app please do it explicitly:
The text was updated successfully, but these errors were encountered: