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

Create a unique logger for mappyfile logger #36

Closed
loicgasser opened this issue Aug 25, 2017 · 3 comments
Closed

Create a unique logger for mappyfile logger #36

loicgasser opened this issue Aug 25, 2017 · 3 comments

Comments

@loicgasser
Copy link
Contributor

@loicgasser loicgasser commented Aug 25, 2017

At the moment logging is imported directly in the different modules, making it impossible to shut him up.

The simple solution would be to create a logger named mappyfile and then import it everywhere.

With a simple note in a script:

logging.getLogger('mappyfile').setLevel(logging.WARNING)

you can set a custom logging level.

geographika added a commit that referenced this issue Aug 25, 2017
@geographika
Copy link
Owner

@geographika geographika commented Aug 25, 2017

Good idea - added. Calling scripts can now use:

logging.basicConfig(level=logging.DEBUG)
logging.getLogger('mappyfile').setLevel(logging.WARNING)
@loicgasser
Copy link
Contributor Author

@loicgasser loicgasser commented Aug 28, 2017

cool! Would you mind creating a new release with all the latest changes?

@loicgasser loicgasser closed this Aug 28, 2017
@geographika
Copy link
Owner

@geographika geographika commented Aug 28, 2017

@loicgasser - done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants