runtime/loglevels.py
author Edouard Tisserant <edouard.tisserant@gmail.com>
Tue, 16 Aug 2022 19:52:49 +0200
branchwxPython4
changeset 3584 8a54fd58a552
parent 1973 cc7a46953471
permissions -rw-r--r--
Runtime: wx.app.mainLoop and twisted reactor now share main thread with runtime.Worker.

This fixes exception when invoking python interactive shell from Runtime's tray
icon right-click menu.

Probably a consequence of wxPython upgrade, together with initial bad idea to
move wx.app.mainloop in non-main thread.
#!/usr/bin/env python
# -*- coding: utf-8 -*-

# See COPYING.Runtime file for copyrights details.

LogLevels = ["CRITICAL", "WARNING", "INFO", "DEBUG"]
LogLevelsCount = len(LogLevels)
LogLevelsDict = dict(zip(LogLevels, range(LogLevelsCount)))
LogLevelsDefault = LogLevelsDict["DEBUG"]