You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
import codecs
import csv
from alluxio import Client
c = Client(host=..., port=39999)
with c.open("/test.csv", "w") as f:
f.write("1,2\n")
with c.open("/test.csv", "r") as alluxio_file:
rdr = csv.reader(codecs.iterdecode(alluxio_file, 'utf-8'), delimiter=',')
for row in rdr:
print(', '.join(row))
# prints out 1, 2
Currently the open() method opens the file in "byte" mode which causes the following error, when you try to run an iterator over the file contents:
It would be very useful to allow the caller to specify that the file be open in "text" mode so that the following code would work without error:
The text was updated successfully, but these errors were encountered: