title: Can't start Windows service written in Python (win32serviceutil)
body: <p>I'm trying to start a simple service example:</p>
  
  <p>someservice.py:</p>
  
  <pre><code>import win32serviceutil 
  import win32service 
  import win32event
  
  class SmallestPythonService(win32serviceutil.ServiceFramework):
      _svc_name_ = "SmallestPythonService"
      _svc_display_name_ = "display service"
  
      def __init__(self, args):
          win32serviceutil.ServiceFramework.__init__(self, args)
          self.hWaitStop = win32event.CreateEvent(None, 0, 0, None)
  
      def SvcStop(self):
          self.ReportServiceStatus(win32service.SERVICE_STOP_PENDING)
          win32event.SetEvent(self.hWaitStop)
  
      def SvcDoRun(self):
          win32event.WaitForSingleObject(self.hWaitStop, win32event.INFINITE)
  
  if __name__=='__main__':
      win32serviceutil.HandleCommandLine(SmallestPythonService)
  </code></pre>
  
  <p>When I run</p>
  
  <pre><code>python someservice.py install
  </code></pre>
  
  <p>everything is fine and the service appears in the Windows service list, but</p>
  
  <pre><code>python someservice.py start
  </code></pre>
  
  <p>fails with "Error 1053: The service did not respond to the start or control request in a timely fashion", but there is not any delay.</p>
  
  <p>I googled a solution, which said it happens when <code>pythonservice.exe</code> can't locate <code>python27.dll</code>. It actually couldn't so I added <code>C:\Python27</code> to <code>PATH</code>. Now <code>pythonservice.exe</code> runs fine, but Error 1053 still there.</p>
  
  <p>I'm running Python 2.7.2 with pywin32 216 on Windows 7 Ultimate with admin privilegies.</p>