i know this question has been asked many times but all answers do not fit my request. I would like to retrieve a csv file that is stored into cloud storage from datalab. In order to re-use the code in a normal application i DO NOT want to use the datalab.storage library but the official cloud storage and without any magic.
Is it possible? Up to now I did:
from google.cloud import storage
client = storage.Client()
bucket = client.get_bucket(BUCKET_NAME)
blob = storage.Blob(gs_path, bucket)
# here I should put something equivalent to
# data = data_obj.read_stream() if using datalab.storage
# %gcs read --object $uri --variable data if using magic
How to do using clean storage library? Thanks