code: def _handle_gcs_url(netloc, ext, urlpath):
      try:
          # Create client to access Google Cloud Storage.
          client = storage.Client()
          # Get bucket from bucket name parsed from URL.
          bucket = client.get_bucket(netloc)
          # Create a blob object from the given filepath.
          urlpath = urlpath[1:] if urlpath.startswith("/") else urlpath
          blob = bucket.blob(urlpath)
          # Provision a temporary file to which to download the blob.
          dest_file = tempfile.NamedTemporaryFile(
              suffix=ext, delete=False, dir=CP_TEMP_DIR.name
          )
          blob.download_to_filename(dest_file.name)
          return dest_file.name
      except DefaultCredentialsError as e:
          LOGGER.error(
              f"Unable to download Google Cloud Storage image to temp file: {e.args[0]}"
          )
          return None
      except NotFound as e:
          # 404 error
          LOGGER.error(
              f"Unable to download Google Cloud Storage image to temp file. {e}"
          )
          dest_file.close()
          return None
      except Exception as e:
          LOGGER.error(
              f"Unable to download Google Cloud Storage image to temp file. {e}"
          )
          if dest_file:
              dest_file.close()
          return None
  
imports: import logging
  import os
  import re
  import shutil
  import sys
  import tempfile
  import urllib.request
  from urllib.parse import parse_qs, unquote, urlparse
  from urllib.request import urlopen
  import boto3
  import numpy
  import pkg_resources
  import scipy.io
  from google.cloud import storage
  from google.cloud.exceptions import NotFound
  from google.auth.exceptions import DefaultCredentialsError
  from ..constants.image import ALL_IMAGE_EXTENSIONS, FILE_SCHEME, PASSTHROUGH_SCHEMES, SUPPORTED_MOVIE_EXTENSIONS
  from ..constants.measurement import FTR_WELL
  from .measurement import is_well_column_token, is_well_row_token
label_desc: Use image node_id 18 for calling a global function with example usage: _handle_gcs_url(netloc, ext, urlpath) and returns: dest_file, None, None, None