diff --git a/qutebrowser/app.py b/qutebrowser/app.py index 83b734158..dc4b629f1 100644 --- a/qutebrowser/app.py +++ b/qutebrowser/app.py @@ -366,9 +366,6 @@ def _init_modules(args, crash_handler): crash_handler: The CrashHandler instance. """ # pylint: disable=too-many-statements - log.init.debug("Initializing messages...") - message.init() - log.init.debug("Initializing save manager...") save_manager = savemanager.SaveManager(qApp) objreg.register('save-manager', save_manager) diff --git a/qutebrowser/utils/message.py b/qutebrowser/utils/message.py index 83bd44ef7..ffa619a4a 100644 --- a/qutebrowser/utils/message.py +++ b/qutebrowser/utils/message.py @@ -30,14 +30,6 @@ from PyQt5.QtWidgets import QApplication from qutebrowser.utils import usertypes, log, objreg, utils -global_bridge = None - - -def init(): - global global_bridge - global_bridge = GlobalMessageBridge() - - def _log_stack(typ, stack): """Log the given message stacktrace. @@ -236,3 +228,6 @@ class MessageBridge(QObject): log_stack: ignored """ self.s_question.emit(question, blocking) + + +global_bridge = GlobalMessageBridge() diff --git a/tests/helpers/messagemock.py b/tests/helpers/messagemock.py index 62a6d1c7f..38fdf3e97 100644 --- a/tests/helpers/messagemock.py +++ b/tests/helpers/messagemock.py @@ -79,7 +79,6 @@ class MessageMock: @pytest.fixture def message_mock(): """Fixture to get a MessageMock.""" - message.init() mmock = MessageMock() mmock.patch() yield mmock