monkey patch subprocess