Philipp Hörist pushed to branch master at gajim / gajim
Commits:
-
5aa9741e
by Philipp Hörist at 2023-05-07T17:21:14+02:00
2 changed files:
Changes:
| ... | ... | @@ -176,6 +176,11 @@ def init() -> None: |
| 176 | 176 | root_log.addHandler(consoleloghandler)
|
| 177 | 177 | root_log.propagate = False
|
| 178 | 178 | |
| 179 | + root_log = logging.getLogger('omemo_dr')
|
|
| 180 | + root_log.setLevel(logging.WARNING)
|
|
| 181 | + root_log.addHandler(consoleloghandler)
|
|
| 182 | + root_log.propagate = False
|
|
| 183 | + |
|
| 179 | 184 | # GAJIM_DEBUG is set only on Windows when using Gajim-Debug.exe
|
| 180 | 185 | # Gajim-Debug.exe shows a command line prompt and we want to redirect
|
| 181 | 186 | # log output to it
|
| ... | ... | @@ -190,11 +195,13 @@ def set_loglevels(loglevels_string: str) -> None: |
| 190 | 195 | def set_verbose() -> None:
|
| 191 | 196 | parseAndSetLogLevels('gajim=DEBUG')
|
| 192 | 197 | parseAndSetLogLevels('.nbxmpp=INFO')
|
| 198 | + parseAndSetLogLevels('.omemo_dr=DEBUG')
|
|
| 193 | 199 | |
| 194 | 200 | |
| 195 | 201 | def set_quiet() -> None:
|
| 196 | 202 | parseAndSetLogLevels('gajim=CRITICAL')
|
| 197 | 203 | parseAndSetLogLevels('.nbxmpp=CRITICAL')
|
| 204 | + parseAndSetLogLevels('.omemo_dr=CRITICAL')
|
|
| 198 | 205 | |
| 199 | 206 | |
| 200 | 207 | def _redirect_output() -> None:
|
| ... | ... | @@ -139,7 +139,7 @@ def __init__(self, client: types.Client) -> None: |
| 139 | 139 | unacknowledged_count=2000)
|
| 140 | 140 | |
| 141 | 141 | self._backend = OMEMOSessionManager(
|
| 142 | - self._own_jid, storage, omemo_config)
|
|
| 142 | + self._own_jid, storage, omemo_config, self._account)
|
|
| 143 | 143 | self._backend.register_signal('republish-bundle',
|
| 144 | 144 | self._on_republish_bundle)
|
| 145 | 145 |