[Buildbot-commits] [Buildbot] #2105: Mercurial hook - exceptions.ValueError: signal only works in main thread

Buildbot nobody at buildbot.net
Fri Sep 23 03:23:03 UTC 2011


#2105: Mercurial hook - exceptions.ValueError: signal only works in main thread
--------------------+--------------------
Reporter:  jpichon  |       Owner:
    Type:  defect   |      Status:  new
Priority:  major    |   Milestone:  0.8.6
 Version:  0.8.4p2  |  Resolution:
Keywords:  hg       |
--------------------+--------------------
Changes (by dustin):

 * keywords:   => hg
 * type:  undecided => defect
 * milestone:  undecided => 0.8.6


Comment:

 So here's what's happening:

 Mercurial is running the hook in a thread.  The hook is using Twisted
 Python, which really, really does not want to run in a thread.  Adding
 `installSignalHandlers=0` avoids the call to `signal(..)`, but has other
 effects -- notably, Twisted does not get SIGCHLD, so it never cleans up
 its children.

 I'm not sure this can be made to work easily.  I suspect that, if we want
 to keep supporting a mercurial hook, it will need to fire off an external
 script that submits the change to the master, rather than trying to do so
 within the Mercurial process.

-- 
Ticket URL: <http://trac.buildbot.net/ticket/2105#comment:4>
Buildbot <http://buildbot.net/>
Buildbot: build/test automation


More information about the Commits mailing list