def __start_mola(self):
        try:
            self.__mola_process = subprocess.Popen(
                'python3 %sdaemon.py' % self.__tmp_path,
                stdout=subprocess.PIPE, 
                shell=True,
                preexec_fn=os.setsid
            )

        except Exception as e:
            Log.crash(e) 
 def add_crash(self, text, *args, **kwargs):
     """Add a crash message to logger"""
     text = '%s %s: %s' % (self.name_prefix, self.name, text)
     Log.crash(text, *args, **kwargs)
import tempfile
from core import settings
from helpers.modules.NotificationModule import NotificationModule


import os
try:
    from win32api import *
    from win32gui import *
    import win32con
except ImportError:
    if os.name == 'nt':
        from core import Log
        Log.crash('python package "pywin32" is required')


class Module(NotificationModule):
    def init(self):
        # Register the Window class.
        wc = WNDCLASS()
        wc.hInstance = GetModuleHandle(None)
        wc.lpszClassName = "PythonTaskbar"
        self.classAtom = RegisterClass(wc)

    def is_available(self):
        return os.name == 'nt'

    def send(self, msg, image=None, sound=None):
        # Create the Window.
        style = win32con.WS_OVERLAPPED | win32con.WS_SYSMENU
        hwnd = CreateWindow(