From: Sommer D. <Det...@ce...> - 2014-10-17 08:35:08
|
Hello, thanks for the answer. The compile now works, but I have some troubles getting the additional comand line parameters to work. When I rund the program without compilation the parameters work without problem, when I compile it the default (install, start, stop, ...) work - but my user defined are alsways rejected with "option xxxx not recognized". I have searched arround, my code seems to be valid - any ideas ? > -----Ursprüngliche Nachricht----- > Von: Thomas Heller [mailto:th...@ct...] > Gesendet: Mittwoch, 15. Oktober 2014 19:58 > An: py2...@li... > Betreff: Re: [Py2exe-users] py2exe, python 3 and OpenSSL ... > > Sorry for the late reply; I have been traveling and then being sick :-( > > Am 27.09.2014 um 11:43 schrieb Sommer Detlef: > > > > Think this does not work. Compile is ok, but when I start the program I get: > > > > Traceback (most recent call last): > > File "boot_service.py", line 180, in <module> > > pywintypes.error: (1063, 'StartServiceCtrlDispatcher', 'Der Dienstprozess > konnte keine Verbindung mit dem Dienstcontroller herstellen.') > > > > During handling of the above exception, another exception occurred: > > > > Traceback (most recent call last): > > File "boot_service.py", line 182, in <module> > > TypeError: 'error' object does not support indexing > > > > Any ideas ? > > There is still a bug in the error handling code; this patch should fix it: > > Index: py2exe/boot_service.py > ========================================================== > ========= > --- py2exe/boot_service.py (revision 758) > +++ py2exe/boot_service.py (working copy) > @@ -179,7 +179,7 @@ > try: > servicemanager.StartServiceCtrlDispatcher() > except win32service.error as details: > - if details[0] == > winerror.ERROR_FAILED_SERVICE_CONTROLLER_CONNECT: > + if details.winerror == > winerror.ERROR_FAILED_SERVICE_CONTROLLER_CONNECT: > win32serviceutil.usage() > else: > win32serviceutil.HandleCommandLine(k) > @@ -192,7 +192,7 @@ > try: > servicemanager.StartServiceCtrlDispatcher() > except win32service.error as details: > - if details[0] == > winerror.ERROR_FAILED_SERVICE_CONTROLLER_CONNECT: > + if details.winerror == > winerror.ERROR_FAILED_SERVICE_CONTROLLER_CONNECT: > win32serviceutil.usage() > else: > # assume/insist that the module provides a HandleCommandLine > function. > > > > > > >> -----Ursprüngliche Nachricht----- > >> Von: Thomas Heller [mailto:th...@ct...] > >> Gesendet: Freitag, 26. September 2014 20:43 > >> An: py2...@li... > >> Betreff: Re: [Py2exe-users] py2exe, python 3 and OpenSSL ... > >> > >> Am 26.09.2014 um 10:15 schrieb Sommer Detlef: > >>> > >>> Perfect - this look very good. Thank you for the help ! > >> > >> Thanks for testing. > >> > >>> One last question - will the python 3 version of py2exe also support > >> "cmdline_style='pywin32'" for windows services. > >> > >> It seems that this simple patch to py2exe/runtime.py will enable this > >> support: > >> > >> @@ -569,13 +570,18 @@ > >> optimize=self.options.optimize)) > >> > >> if target.exe_type == "service": > >> + > >> + cmdline_style = getattr(target, "cmdline_style", "py2exe") > >> + if cmdline_style not in ["py2exe", "pywin32", "custom"]: > >> + raise RuntimeError("cmdline_handler invalid") > >> + > >> # code for services > >> # cmdline_style is one of: > >> # py2exe > >> # pywin32 > >> # custom > >> code_objects.append( > >> - compile("cmdline_style = 'py2exe'; service_module_names > >> = %r" % (target.modules,), > >> + compile("cmdline_style = %r; service_module_names = %r" > >> % (cmdline_style, target.modules,), > >> "<service_info>", "exec", > >> optimize=self.options.optimize)) > >> > >> > >> > >> > >> > >> ------------------------------------------------------------------------------ > >> Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer > >> Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS > Reports > >> Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper > >> Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer > >> > http://pubads.g.doubleclick.net/gampad/clk?id=154622311&iu=/4140/ostg.cl > >> ktrk > >> _______________________________________________ > >> Py2exe-users mailing list > >> Py2...@li... > >> https://lists.sourceforge.net/lists/listinfo/py2exe-users > > > > ------------------------------------------------------------------------------ > > Meet PCI DSS 3.0 Compliance Requirements with EventLog Analyzer > > Achieve PCI DSS 3.0 Compliant Status with Out-of-the-box PCI DSS Reports > > Are you Audit-Ready for PCI DSS 3.0 Compliance? Download White paper > > Comply to PCI DSS 3.0 Requirement 10 and 11.5 with EventLog Analyzer > > > http://pubads.g.doubleclick.net/gampad/clk?id=154622311&iu=/4140/ostg.cl > ktrk > > > > > > ------------------------------------------------------------------------------ > Comprehensive Server Monitoring with Site24x7. > Monitor 10 servers for $9/Month. > Get alerted through email, SMS, voice calls or mobile push notifications. > Take corrective actions from your mobile device. > http://p.sf.net/sfu/Zoho > _______________________________________________ > Py2exe-users mailing list > Py2...@li... > https://lists.sourceforge.net/lists/listinfo/py2exe-users |