#954: win32 slave hangs when patching (when using buildbot try)
---------------------+------------------------------------------------------
Reporter: mornfall | Owner:
Type: defect | Status: new
Priority: major | Milestone: undecided
Version: 0.7.11 | Keywords:
---------------------+------------------------------------------------------
Seems that buildbot relies on FIFO buffering to write all of a diff file
to patch.exe's stdin before starting to read its output from stdout. This
only works if the diff is small enough to fit in the buffer (which is
probably smaller on win32 than on other common platforms). Anyway, the
following version of doPatch for slave/commands.py works better (sorry,
but win32 is too much of a pain for me to go and try to produce a diff):
{{{
def doPatch(self, res):
patchlevel, diff = self.patch
command = [getCommand("patch"), '-p%d' % patchlevel, "-i",
".buildbot-diff"]
dir = os.path.join(self.builder.basedir, self.workdir)
# mark the directory so we don't try to update it later
open(os.path.join(dir, ".buildbot-patched"),
"w").write("patched\n")
open(os.path.join(dir, ".buildbot-diff"), "w").write(diff)
# now apply the patch
c = ShellCommand(self.builder, command, dir,
sendRC=False, timeout=self.timeout,
usePTY=False)
self.command = c
d = c.start()
d.addCallback(self._abandonOnFailure)
return d
}}}
--
Ticket URL: <http://buildbot.net/trac/ticket/954>
Buildbot <http://buildbot.net/>
Buildbot: build/test automation
------------------------------------------------------------------------------
This SF.net email is sponsored by
Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev
_______________________________________________
Buildbot-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/buildbot-commits