A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2007-September/074696.html below:

[Python-Dev] Daily Windows Installers

[Python-Dev] Daily Windows Installers [Python-Dev] Daily Windows InstallersDavid Bolen db3l.net at gmail.com
Tue Sep 18 00:19:07 CEST 2007
On 9/17/07, Trent Mick <trentm at activestate.com> wrote:

> How do you tell Windows to do that?

Via the SetErrorMode call.

Since the Windows buildbot already uses the win32 extensions, I just
used the existing win32api wrapper (although through ctypes is very
easy too).  In my case I just surrounded the reactor.spawnProcess call
in buildbot/slave/commands.py with:

old_err_mode = win32api.SetErrorMode(7)
and
win32api.SetErrorMode(old_err_mode)

I suppose I should really tweak that to 0x8007 rather than just 7 to
include missing file dialogs (like when a removeable device is not
available).

Since the error mode is inherited by child processes (unless
explicitly overridden in the CreateProcess call), this effectively
covers the primary child process and any others it may spawn during
execution, so it works even though buildbot uses an intermediate
command interpreter to execute whatever command is requested.

We had a bit of discussion about this recently on the py3k devel list,
in regards to failures in the python buildbot tests, in regards to
more local changes within Python itself.

-- David
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4