# HG changeset patch # User Goffi # Date 1580058490 -3600 # Node ID 2b0f739f8a4601ee88b1a99cc8340e8cec889feb # Parent c3ce8c997fdf4833cd78822cd5f55150486c8659 plugin manhole: added "C" to namespace diff -r c3ce8c997fdf -r 2b0f739f8a46 sat/memory/params.py --- a/sat/memory/params.py Sun Jan 26 18:08:09 2020 +0100 +++ b/sat/memory/params.py Sun Jan 26 18:08:10 2020 +0100 @@ -218,7 +218,8 @@ @param profile_key: profile name or key which can be C.PROF_KEY_ALL for all profiles C.PROF_KEY_DEFAULT for default profile - @param return_profile_keys: if True, return unmanaged profile keys (like C.PROF_KEY_ALL). This keys must be managed by the caller + @param return_profile_keys: if True, return unmanaged profile keys (like + C.PROF_KEY_ALL). This keys must be managed by the caller @return: requested profile name @raise exceptions.ProfileUnknownError: profile doesn't exists @raise exceptions.ProfileNotSetError: if C.PROF_KEY_NONE is used diff -r c3ce8c997fdf -r 2b0f739f8a46 sat/plugins/plugin_dbg_manhole.py --- a/sat/plugins/plugin_dbg_manhole.py Sun Jan 26 18:08:09 2020 +0100 +++ b/sat/plugins/plugin_dbg_manhole.py Sun Jan 26 18:08:10 2020 +0100 @@ -57,6 +57,7 @@ f = protocol.ServerFactory() namespace = { "host": self.host, + "C": C, "jid": jid, } f.protocol = lambda: TelnetTransport(TelnetBootstrapProtocol, diff -r c3ce8c997fdf -r 2b0f739f8a46 sat/plugins/plugin_misc_debug.py --- a/sat/plugins/plugin_misc_debug.py Sun Jan 26 18:08:09 2020 +0100 +++ b/sat/plugins/plugin_misc_debug.py Sun Jan 26 18:08:10 2020 +0100 @@ -1,5 +1,4 @@ #!/usr/bin/env python3 -# -*- coding: utf-8 -*- # SàT plugin for managing raw XML log # Copyright (C) 2009-2016 Jérôme Poisson (goffi@goffi.org) @@ -17,12 +16,13 @@ # You should have received a copy of the GNU Affero General Public License # along with this program. If not, see . +import json from sat.core.i18n import _ from sat.core.log import getLogger +from sat.core.constants import Const as C + log = getLogger(__name__) -from sat.core.constants import Const as C -import json PLUGIN_INFO = { C.PI_NAME: "Debug Plugin",