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

Dependency injection for logger #28

Open
yashpatel6 opened this issue Nov 29, 2022 · 1 comment
Open

Dependency injection for logger #28

yashpatel6 opened this issue Nov 29, 2022 · 1 comment

Comments

@yashpatel6
Copy link
Contributor

    Disabling the warning works, but it may be a code smell. Have you considered refactoring `__init__` to use dependency injection for the logger?

Originally posted by @dan-knight in #27 (comment)

@dan-knight
Copy link

dan-knight commented Nov 30, 2022

This will mean that the private _logger attribute won't be accessed directly, so the pylint warnings will go away. If we make this change, be sure to also remove the relevant pylint: disable comments from unit tests.

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

2 participants