Skip to content
Snippets Groups Projects
Commit 5a183928 authored by André Anjos's avatar André Anjos :speech_balloon:
Browse files

[settings] Better logging

parent 77794200
No related branches found
No related tags found
1 merge request!194Scheduler
...@@ -83,7 +83,7 @@ LOGGING = { ...@@ -83,7 +83,7 @@ LOGGING = {
'class': 'logging.NullHandler', 'class': 'logging.NullHandler',
}, },
'console': { 'console': {
'level': 'DEBUG', 'level': 'INFO',
'class': 'logging.StreamHandler', 'class': 'logging.StreamHandler',
'formatter': 'simple', 'formatter': 'simple',
}, },
...@@ -93,13 +93,9 @@ LOGGING = { ...@@ -93,13 +93,9 @@ LOGGING = {
} }
}, },
'loggers': { 'loggers': {
'beat.web': { 'beat': {
'handlers': ['console', 'mail_admins'], 'handlers': ['console', 'mail_admins'],
}, },
'beat.core': {
'handlers': ['discard'],
'propagate': False, #don't e-mail those!
},
'beat.web.attestations.management.commands': { 'beat.web.attestations.management.commands': {
'handlers': ['console'], 'handlers': ['console'],
'propagate': False, #don't e-mail those! 'propagate': False, #don't e-mail those!
......
...@@ -44,7 +44,10 @@ elif 'beat.cmdline' in sys.argv: ...@@ -44,7 +44,10 @@ elif 'beat.cmdline' in sys.argv:
# make it in-memory # make it in-memory
DATABASES['default']['NAME'] = ':memory:' DATABASES['default']['NAME'] = ':memory:'
PREFIX = os.path.join(os.getcwd(), 'test_prefix') LOGGING['handlers']['console']['level'] = 'DEBUG'
import tempfile
PREFIX = tempfile.mkdtemp(prefix='beat_')
ALGORITHMS_ROOT = os.path.join(PREFIX, 'algorithms') ALGORITHMS_ROOT = os.path.join(PREFIX, 'algorithms')
LIBRARIES_ROOT = os.path.join(PREFIX, 'libraries') LIBRARIES_ROOT = os.path.join(PREFIX, 'libraries')
DATABASES_ROOT = os.path.join(PREFIX, 'databases') DATABASES_ROOT = os.path.join(PREFIX, 'databases')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment