Developer information¶
The information here is intended to get Magpie developers up-to-speed for working with the codebase.
Logging¶
The logging level is controlled by the config.MAGPIE_LOG_LEVEL variable.
It can consist in a single value defining the default logging level for all modules, like:
MAGPIE_LOG_LEVEL=DEBUG
or it can be a comma-separated list of module=LEVEL value pairs, like:
MAGPIE_LOG_LEVEL=INFO,magpie=DEBUG,celery=DEBUG
In this case, the default logging level will be INFO but all messages issued from the
magpie and celery modules will be logged with DEBUG severity.
Pretty-printing functions¶
The magpie.util module has a few pretty-printing functions:
Coding style¶
We mostly conform to PEP8, with a max line length of 120.
Linting is performed by Ruff, use the following to run it:
just check
Docstrings¶
Docstrings are written in the markdown format, using the Google-style for docstrings.
Documentation¶
Colon fences¶
When writing documentation in markdown, you can use colon fences instead of the standard triple backquotes to render directives. This is especially useful for admonitions and the like as the fenced content will be rendered as markdown by your editor and not as monospace text.