semvec/pypi-packages huggingface dataset:
p2.logging 0.3.0
A P2 package to deal with basic logging config
License: BSD
Keywords: p2.logging

==========
p2.logging
==========


.. image:: https://img.shields.io/pypi/v/p2.logging.svg
        :target: https://pypi.python.org/pypi/p2.logging


A P2 class for basic logging

* Free software: BSD license


Features
--------

Usage:

.. code-block:: python

        # To use the file logger...
        from p2.logging import Logger

        log_obj = Logger(filename='logfile', level=logging.INFO)
        logger = log_obj.getLogger()

        # To use the Http logger...
        from p2.logging import HttpLogger

        log_obj = HttpLogger(
            url = '...'         # POST endpoint
            token = '...',      # The Authorization token being used (if needed by log server)
            silent = False,     # if True log is printed on stdout as well
            level = '...'       # severity, defaults to logging.DEBUG
            name = '...'        # module/component name
            )

        logger = log_obj.getLogger()



Credits
-------

This package was created with `Cookiecutter
<https://github.com/cookiecutter/cookiecutter>`_ and the
`cookiecutter-namespace-template
<https://github.com/veit/cookiecutter-namespace-template>`_ project template.