[PATCH 6 of 6] install-iis: use logging.config.fileConfig instead of paste.script copy
Thomas De Schampheleire
patrickdepinguin at gmail.com
Sat Dec 29 21:50:20 UTC 2018
# HG changeset patch
# User Thomas De Schampheleire <thomas.de_schampheleire at nokia.com>
# Date 1546119008 -3600
# Sat Dec 29 22:30:08 2018 +0100
# Node ID 644825b2d19bc5842064eea70932d826a8474ebf
# Parent bea4841809a71cdaf19950703b37f4ca5a896e5f
install-iis: use logging.config.fileConfig instead of paste.script copy
paste.script.util.logging_config is an old copy of logging.config from
Python 2.5.1 (see [1]). There are no paste-specific details in it.
In other places, we are always using logging.config directly, there is no
reason not to do it in install-iis.
[1] https://bitbucket.org/wilig/pastescript/commits/04d0db6b2f5ab360bdaa5b10511d969a24fde0ec
diff --git a/docs/setup.rst b/docs/setup.rst
--- a/docs/setup.rst
+++ b/docs/setup.rst
@@ -544,7 +544,7 @@ Example WSGI dispatch script:
site.addsitedir("/srv/kallithea/venv/lib/python2.7/site-packages")
ini = '/srv/kallithea/my.ini'
- from paste.script.util.logging_config import fileConfig
+ from logging.config import fileConfig
fileConfig(ini)
from paste.deploy import loadapp
application = loadapp('config:' + ini)
@@ -560,7 +560,7 @@ Or using proper virtualenv activation:
os.environ['HOME'] = '/srv/kallithea'
ini = '/srv/kallithea/kallithea.ini'
- from paste.script.util.logging_config import fileConfig
+ from logging.config import fileConfig
fileConfig(ini)
from paste.deploy import loadapp
application = loadapp('config:' + ini)
diff --git a/kallithea/bin/kallithea_cli_iis.py b/kallithea/bin/kallithea_cli_iis.py
--- a/kallithea/bin/kallithea_cli_iis.py
+++ b/kallithea/bin/kallithea_cli_iis.py
@@ -30,7 +30,7 @@ import os
def __ExtensionFactory__():
from paste.deploy import loadapp
- from paste.script.util.logging_config import fileConfig
+ from logging.config import fileConfig
fileConfig('%(inifile)s')
application = loadapp('config:%(inifile)s')
More information about the kallithea-general
mailing list