Mercurial > libervia-backend
diff src/core/constants.py @ 991:05e02f8b7eb4
core: logging refactoring, first step:
- added a core.log module
- 3 backends can be used: basic, standard (python's logging module) or twisted
- colors can be used
- the module has been made to be used by frontends, it should work in exotic environments like pyjamas
- logging basic configuration is now made in sat.tac
- core.log configuration is inspired from python standard logging, and use it when possible
- getLogger should be used the same way as for standard logging
author | Goffi <goffi@goffi.org> |
---|---|
date | Sat, 19 Apr 2014 00:02:38 +0200 |
parents | f0e407709d8e |
children | 652c01ca69b1 |
line wrap: on
line diff
--- a/src/core/constants.py Fri Apr 18 23:36:52 2014 +0200 +++ b/src/core/constants.py Sat Apr 19 00:02:38 2014 +0200 @@ -72,6 +72,12 @@ # names of widely used plugins TEXT_CMDS = 'TEXT-COMMANDS' + ## Logging ## + LOG_BACKEND_STANDARD = 'standard' + LOG_BACKEND_TWISTED = 'twisted' + LOG_BACKEND_BASIC = 'basic' + LOG_BASE_LOGGER = 'root' + ## Misc ## SAVEFILE_DATABASE = "sat.db" IQ_SET = '/iq[@type="set"]'