Skip to content
Create a gist now

Instantly share code, notes, and snippets.

Embed URL


Subversion checkout URL

You can clone with
Download ZIP
Use GCS (Google cloudstoarge) to replace the app engine blobstore. You can use the Blobstore service to access GCS.

Great example.
But when i try to run my project i get an exception inside in this line

dyn.serving_url = images.get_serving_url(
blobstore.create_gs_key('/gs' + gcs_file_name), secure_url=True)

I have tried to fix this but it doesn't work. What might be the issue here ??

---- this is the error message ---
The server has either erred or is incapable of performing the requested operation.

Traceback (most recent call last):
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/", line 1535, in call
rv = self.handle_exception(request, response, e)
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/", line 1529, in call
rv = self.router.dispatch(request, response)
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/", line 1278, in default_dispatcher
return route.handler_adapter(request, response)
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/", line 1102, in call
return handler.dispatch()
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/", line 572, in dispatch
return self.handle_exception(e,
File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/", line 570, in dispatch
return method(args, *kwargs)
File "/base/data/home/apps/s~kunajamapp/1.374701545509525083/", line 77, in post
serving_url = gcs_serving_url( entity )
File "/base/data/home/apps/s~kunajamapp/1.374701545509525083/", line 38, in gcs_serving_url
gcs_dyn.serving_url = images.get_serving_url( blobstore.create_gs_key( '/gs'+gcs_file_name ), secure_url = True )
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/api/images/", line 1793, in get_serving_url
return rpc.get_result()
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/api/", line 612, in get_result
return self.get_result_hook(self)
File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/api/images/__init
.py", line 1891, in get_serving_url_hook
raise _ToImagesError(e, readable_blob_key)


Are you sure the image is in the bucket?


i got a question, i'm using flow.js and ng-flow for angluar js and running into the same file name problem... have you ran into that and if how did you deal with it...


I have revised the code. The updated version can be found here:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.