CSV File read from mac location

Need some help folks with very basic issue
Have a csv file in my downloads folder of mac and I am not able to read that properly. Any help is appreciated.

I am using this code

import csv
with open (’/Users/myname/Downloads/combine.csv’,‘r’) as csv_file :
csv_reader = csv.reader (csv_file)

Getting this error

FileNotFoundError Traceback (most recent call last)
/tmp/ipykernel_36/3401793020.py in
1 import csv
----> 2 with open (’/Users/myname/Downloads/combine.csv’,‘r’) as csv_file :
3 csv_reader = csv.reader (csv_file)

FileNotFoundError: [Errno 2] No such file or directory: ‘/Users/myname/Downloads/combine.csv’

Check if the file is present on your PC…
As the error says, FileNotFound

It is there , I am very sure :blush:

What are you using to run the notebooks?

Using binder notebook

So, how is binder notebook (ran on some server, probably far away from you) supposed to access your computer and files?
Wouldn’t it be a bit dangerous if you could run notebooks, probably from an unknown source, which can access your files? :stuck_out_tongue:

You need to upload the file to the notebook. I think you can do so within jovian notebook viewer (and I think it’s a bit more persistent when using binder).
You can also do it from within the binder notebook (at least the UI should make it possible to do so).

1 Like

Got it , that makes sense. Thank you