This repository has been archived by the owner on Feb 7, 2019. It is now read-only.
Signal for missing keys #9
Comments
I think it's a fine idea to add blinker signals for critical events, so I'm all for that. I don't want to add support for adding keys automatically, because I think it's a likely uncommon use case and could be potentially dangerous if you didn't know what you were doing. I'm willing to be convinced otherwise, but that's my first response. |
I agree, I want this signal to make it an option, not a built-in thing. I'll provide you an example soon. |
Done. I don't know if a global event is better than a class level event. from flask.ext.featureflags import missing_feature
@missing_feature.connect
def f(obj, feature):
pass If I change it to class level: ff = FeatureFlag()
@ff.missing_feature.connect
def f(obj, feature):
# obj is my FeatureFlag instance
pass |
catermelon
pushed a commit
that referenced
this issue
Aug 13, 2014
When a feature isn't handled by anything, send a signal. Ref #9
Closing it, because it is merged. |
thanks! |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I want to add the key to my sqlalchemy database if it does not exist in any other handler. I can listen to some flask signal in this case to do that.
Is it a good idea? I can work on it, but maybe others have better ideas about how to handle it.
The text was updated successfully, but these errors were encountered: