Re: Getting exit code of pipe()

2017-02-12 Thread Xuchen Yao
an error exit code? > > You could set checkCode to True > spark.apache.org/docs/latest/api/python/pyspark.html? > highlight=pipe#pyspark.RDD.pipe > > Otherwise maybe you want to output the status into stdout so you could > process it individually. > > > _____

Getting exit code of pipe()

2017-02-10 Thread Xuchen Yao
Hello Community, I have the following Python code that calls an external command: rdd.pipe('run.sh', env=os.environ).collect() run.sh can either exit with status 1 or 0, how could I get the exit code from Python? Thanks! Xuchen