[Twisted-Python] git clone with spawnProcess() can prevent socket data flow, any clue why?

Martin Nordholts enselic at gmail.com
Sat Aug 28 03:31:07 MDT 2010


On 08/28/2010 09:34 AM, Martin Nordholts wrote:
> Hi
>
> I am getting a weird problem where git cloning with
> reactor.spawnProcess() fails for some repositories. It appears as if
> Twisted blocks reading from the server socket that git packs should come
> on.

Started to debug this myself in Twisted, and it turns out that if I 
disable _setupChild() in twisted.internet.process.Process, the sample 
program that clones GIMP with spawnProcess() works as expected.


--- Twisted-10.1.0-orig/twisted/internet/process.py
+++ Twisted-10.1.0/twisted/internet/process.py
@@ -619,6 +619,9 @@ class Process(_BaseProcess):
                     original.
          """

+        # Don't do this..
+        return
+
          debug = self.debug_child
          if debug:
              errfd = sys.stderr


I'll see if I can pinpoint the bug...

  / Martin




More information about the Twisted-Python mailing list