Opened 8 years ago

Closed 8 years ago

#3728 closed enhancement (wontfix)

os.popen3 usage cause lags in launch() function

Reported by: franck34 Owned by: pkropf
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 8 years ago by cboos

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 8 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 8 years ago by cboos

  • Resolution set to wontfix
  • Status changed from new to closed

Works fine in the 0.11 version.

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

Add Comment

Modify Ticket

as closed The owner will remain pkropf.
The resolution will be deleted. Next status will be 'reopened'.

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

Note: See TracTickets for help on using tickets.