Using the GCS python client, deleting a blob doesn't raise any exception. But performing GET on the URI that was just deleted, still returns the resource. The following code is part of a single file Flask app.
from google.cloud import storage as gstorage
storage_client = gstorage.Client()
storage_bucket = storage_client.get_bucket(app.config['STORAGE_BUCKET'])
@bp.route('/verify', methods=['POST'])
def post_verification_photo():
...
crs.execute('SELECT uri FROM photo WHERE id=%s', (photoId,))
photoUri = crs.fetchone()[0]
storage_bucket.delete_blob(photoUri[photoUri.rindex('/')+1:])
Note that the object was created with Cache-Control: public, max-age=9999999
header, and also was made public and non-resumable in the metadata.
After execution, there is no error, but GETting the full URI prefixed by the bucket URI still returns the object. Am I confused over the actual use of these methods? Or does the API take some amount of time to remove it from their network? Or, something else?