This is an automatically generated e-mail. To reply, visit: http://reviewboard-fedoraserver.rhcloud.com/r/127/

src/rolekit/util.py (Diff revision 1)
44
    Create a temporary in-memory file object to store input for

Per documentation, "except that data is spooled in memory until the file size exceeds max_size, or until the file’s fileno() method is called, at which point the contents are written to disk and operation proceeds as with TemporaryFile()".

subprocess does call fileno(), so the data will end up on disk.

I suppose it would be ideally clean to use a pipe instead and write data to it similarly to the way we collect output, but that’s also much more work…

shrug This works as well.


- Miloslav Trmac


On leden 20th, 2015, 6:58 odp. CET, Stephen Gallagher wrote:

Review request for RoleKit Mailing List, Miloslav Trmac, Stephen Gallagher, and Thomas Woerner.
By Stephen Gallagher.

Updated Led. 20, 2015, 6:58 odp.

Repository: rolekit

Description

Add utility routine for passing stdin into subprocesses

Diffs

  • src/rolekit/util.py (PRE-CREATION)
  • src/rolekit/async.py (0f9ddaac1beb27cebdf41ca0383a62a807c4fcb6)

View Diff