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

No great way to override logger #36

Open
di opened this issue Jan 5, 2017 · 0 comments
Open

No great way to override logger #36

di opened this issue Jan 5, 2017 · 0 comments

Comments

@di
Copy link
Owner

di commented Jan 5, 2017

There's currently no way to turn off logging when using Vlads programmatically (i.e. not from the commandline) and by default it logs a lot. Workaround for now:

class MyVlad(Vlad):
    def __init__(self, *args, **kwargs):

        super().__init__(*args, **kwargs)

        class DummyLogger():
            def __init__(self):
                pass

            def __getattr__(self, name):
                return (lambda *x: None)

        self.logger = DummyLogger()
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

1 participant