Please sign in to comment.
fix _raise_deferred_exc() (pantsbuild#7008)
### Problem The `_raise_deferred_exc(self)` method in `daemon_pants_runner.py` hasn't ever been tested. As a result, it causes an easily fixable error: the issue can be easily reproduced if you register an option twice in the same task and then run with pantsd enabled (you get the wrong exception, because `exc_type` isn't needed to construct the exception again, that's what `exc_value` is for). ### Solution - Appropriately destructure `sys.exc_info()` (if that was what was used to populate `self._deferred_exception`) and re-raise the exception with its original traceback. ### Result This error is fixed, but not yet tested -- see pantsbuild#7220.
- Loading branch information...
Showing with 10 additions and 8 deletions.