def unzip_from_uri(uri, layer_zip_path, unzip_output_dir, progressbar_label):
try:<EOL><INDENT>get_request = requests.get(uri, stream=True, verify=os.environ.get('<STR_LIT>', True))<EOL>with open(layer_zip_path, '<STR_LIT:wb>') as local_layer_file:<EOL><INDENT>file_length = int(get_request.headers['<STR_LIT>'])<EOL>with progressbar(file_length, progressbar_label) as p_bar:<EOL><INDENT>for data in get_request.iter_content(chunk_size=None):<EOL><INDENT>local_layer_file.write(data)<EOL>p_bar.update(len(data))<EOL><DEDENT><DEDENT><DEDENT>unzip(layer_zip_path, unzip_output_dir, permission=<NUM_LIT>)<EOL><DEDENT>finally:<EOL><INDENT>path_to_layer = Path(layer_zip_path)<EOL>if path_to_layer.exists():<EOL><INDENT>path_to_layer.unlink()<EOL><DEDENT><DEDENT>
Download the LayerVersion Zip to the Layer Pkg Cache

Parameters
----------
uri str
    Uri to download from
layer_zip_path str
    Path to where the content from the uri should be downloaded to
unzip_output_dir str
    Path to unzip the zip to
progressbar_label str
    Label to use in the Progressbar