Module pipelines.rj_cor.meteorologia.radar.precipitacao.utils
General utils for setting rain dashboard using radar data.
Functions
def download_blob(bucket_name, source_blob_name, destination_file_name) ‑> None
-
Downloads a blob mencioned on source_blob_name from bucket_name and save it on destination_file_name.
def list_blobs_with_prefix(bucket_name, prefix, delimiter=None)
-
Lists all the blobs in the bucket that begin with the prefix.
This can be used to list all blobs in a "folder", e.g. "public/".
The delimiter argument can be used to restrict the results to only the "files" in the given "folder". Without the delimiter, the entire tree under the prefix is returned. For example, given these blobs:
a/1.txt a/b/2.txt
If you specify prefix ='a/', without a delimiter, you'll get back:
a/1.txt a/b/2.txt
However, if you specify prefix='a/' and delimiter='/', you'll get back only the file directly under 'a/':
a/1.txt
As part of the response, you'll also get back a blobs.prefixes entity that lists the "subfolders" under
a/
:a/b/