Python 3.7 script as windows service RRS feed

  • Question

  • I don't even know where to ask my question.

    I have a Python script that must work as service in Windows 10/Windows Server 2012. Code works fine without code block for running as service.

    I've installed service, but can't run it.

    If I'm trying to run it with command python pyxlsql.py start 

    Debugging service pyXLSQL - press Ctrl+C to stop.

    Error 0xC0000003 - The instance's SvcRun() method failed

    <Error getting traceback - traceback.print_exception() failed

    (null): (null)

    From IDE IntelliJ:

    pywintypes.error: (1063, 'StartServiceCtrlDispatcher'

    From services.msc 

    code error 1053

    Is it better to make an exe package first and then install it?

    • Moved by Baron Bi Thursday, November 8, 2018 7:58 AM
    Tuesday, October 30, 2018 7:44 PM

All replies

  • Hi,

    thanks for posting here.

    This forum is about desktop application development with Microsoft products. For your case, I suggest you post on Python forum for better support.


    Your understanding and cooperation will be grateful.

    Best Regards,

    Baron Bi

    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Wednesday, October 31, 2018 1:34 AM