How to read contents of a CSV file inside zip file using spark (python)
You need to ensure the package spark-csv is loaded; e.g., by invoking the spark-shell with the flag --packages com.databricks:spark-csv_2.11:1.4.0. After that you can use sc.textFile as you did, or sqlContext.read.format("csv").load. You might need to use csv.gz instead of just zip; I don't know, I haven't tried.