Commit Graph

14 Commits (e5419a273874d23b062f6ce6c229b7ac14c66a44)

Author SHA1 Message Date
Matt Clay 982c4557d2 Python 3 fixes for async_wrapper and async_status. (#4671) 8 years ago
Matt Clay 05c6707a32 Make async_wrapper ignore '_' as an argsfile. (#4678)
This provides support for passing additional positional parameters to async_wrapper.
Additional parameters will be used by the upcoming async support for Windows.
8 years ago
James S. Martin 978716cf4c Shows messages for uncaught exceptions from called modules in async_wrapper output. (#4591) 8 years ago
James Cammarata b75f305079 Ensure async wrapper and status return consistent fields 8 years ago
David Shrewsbury 4e239f6ce0 Use os.rename() in async_wrapper
Because the async_status module will read from the same file that
the async_wrapper module is writing, it's possible that the file
may not be fully synced during a read, causing spurious failures.
Use a temp file to do an atomic operation on the file. We can't
use atomic_move() here as that doesn't work properly under async.

Also, let's not read concurrently from the same file the subprocess
is writing to. Instead, capture stdout/stderr via PIPE and write to
the file to avoid nasty races.
8 years ago
Brian Coca a1e6311197 reverted need for module utils imports 9 years ago
Brian Coca ab4ec24813 added missing import
readded raise
9 years ago
Brian Coca 4a0c483e09 exception ans sys.exit fixes 9 years ago
Toshio Kuratomi f9b28aaae3 Fix exception handling in async_wrapper 9 years ago
Brano Zarnovican 3456c24b96 Py2.4: SystemExit in async_wrapper is not an error - compatibility fix
Prior to Python 2.5, SystemExit was a subclass of Exception.
In Py2.4, this is causing extra error output on valid sys.exit(0).

(Toshio) Call sys.exit from inside of the SystemExit exception handler so py2.4 and py2.5+ behaviour matches
9 years ago
codemeup @ Work 1e0bb94ced Fixing compile time errors irt (, e => as e, print(), ocat now 0o not 0) exception handling for Python 3 (#3851)
* Fixing compile time errors irt a) exception handling for Python 3 in util, also: b) problem octal usage (fixed) and c) print json_dump -> print(json_dump(xyz) ... et al

* This code was not Python 2.4 compliant. Octal codes and exception handling is now working with Py 2.4, 2.6, & 3.5.

* Fixing formating (or rather reverting an non 2.4 compatible change). Works in compile & runtime checking.

* a) revert to use print sys.stderr not fail_json; b) fixed var name in exception

* Python 3 compatible print (print >>sys.stderr will generate a TypeError - now uses sys.stderr.write instead).
9 years ago
Toshio Kuratomi 6e5b09f3a8 Allow async to not need an args file since new-style modules have args embedded 9 years ago
Brian Coca d192e2c3e3 code cleanup and reoorg, renamed vars and functions to actual purpose
reneabled logging of steps
9 years ago
Michael DeHaan cec519f70e Move internal category to utilities to remove one more category from the left hand menu, keeping it concise. 10 years ago