Opened 10 years ago

Closed 9 years ago

#3728 closed enhancement (wontfix)

os.popen3 usage cause lags in launch() function

Reported by: franck34 Owned by: Peter Kropf
Priority: high Component: GraphvizPlugin
Severity: normal Keywords: mod_python, popen, subprocess
Cc: Trac Release: 0.10


Commands launched by launch() function are working, but a lag of 20/30 sec occur after when using apache2+mod_python

Here is my fix, don't know if it's good or not, but it's working for me :

    def launch(self, cmd, input):
        """Launch a process (cmd), and returns exitcode, stdout + stderr"""
        p = subprocess.Popen(cmd, shell=True,stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
        (p_in, p_out, p_err) = (p.stdin, p.stdout, p.stderr)
        if input:
        out =
        err =
        return out, err

Attachments (0)

Change History (3)

comment:1 Changed 10 years ago by Christian Boos

subprocess is now used for the 0.11 version of the plugin. I don't know really, but it seems unlikely that the 0.10 version will adopt this change.

Closing as worksforme?

comment:2 Changed 10 years ago by franck34

Not until change adopted, as you said about subprocess, or this patch applied.

Should be great to have the feedback of pkropf too .


comment:3 Changed 9 years ago by Christian Boos

Resolution: wontfix
Status: newclosed

Works fine in the 0.11 version.

The maintenance of the 0.10 version of the plugin is up for adoption...

Modify Ticket

Change Properties
Set your email in Preferences
as closed The owner will remain Peter Kropf.
The resolution will be deleted.

Add Comment

E-mail address and name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.