Mercurial > libervia-web
diff twisted/plugins/libervia_server.py @ 1509:106bae41f5c8
massive refactoring from camelCase -> snake_case. See backend commit log for more details
author | Goffi <goffi@goffi.org> |
---|---|
date | Sat, 08 Apr 2023 13:44:11 +0200 |
parents | 7e63fdb272e5 |
children | eb00d593801d |
line wrap: on
line diff
--- a/twisted/plugins/libervia_server.py Fri Apr 07 15:20:40 2023 +0200 +++ b/twisted/plugins/libervia_server.py Sat Apr 08 13:44:11 2023 +0200 @@ -160,7 +160,7 @@ # so here is the best place. from sat.core import log_config - log_config.satConfigure(C.LOG_BACKEND_TWISTED, C, backend_data=options) + log_config.sat_configure(C.LOG_BACKEND_TWISTED, C, backend_data=options) class Options(usage.Options): @@ -182,7 +182,7 @@ # on the command line. # FIXME: must be refactored + code can be factorised with backend - config_parser = config.parseMainConf() + config_parser = config.parse_main_conf() self.handleDeprecated(config_parser) for param in self.optParameters + OPT_PARAMETERS_CFG: name = param[0] @@ -190,7 +190,7 @@ try: value = os.getenv(env_name) if value is None: - value = config.getConfig( + value = config.config_get( config_parser, C.CONFIG_SECTION, name, Exception) try: param[2] = param[4](value) @@ -210,7 +210,7 @@ replacements = (("ssl_certificate", "tls_certificate"),) for old, new in replacements: try: - value = config.getConfig(config_parser, C.CONFIG_SECTION, old, Exception) + value = config.config_get(config_parser, C.CONFIG_SECTION, old, Exception) except (configparser.NoSectionError, configparser.NoOptionError): pass else: