Created a new python Flask app-engine python project and want to use the static files from Google cloud storage. I am using this yaml.file: Where in the app engine do you link to storage https://storage.googleapis.com/<your-bucket-name>/static/ with /static in the app-engine? It is not clear from the documentation. Answer You can’t use file stored on Google Cloud Storage as static folder
Tag: google-app-engine
TypeError: ‘NoneType’ object is not subscriptable on GAE instance assigning JSON to python variable
I’m getting an error TypeError: ‘NoneType’ object is not subscriptable when assigning JSON to a python variable like this sheet_id = data[“sheetID”]. It only happens on my Google App Engine instance. I don’t get it when running my Flask app locally and sending POST requests to the app with Postman. Here’s the code snippet The strange thing is that the
Calling Firestore Database from another Cloud Project shows “Permission Error”
After reading every piece of question, documentation available online, we couldn’t find a solution, so posting a question here. Our Setup : Project FB: Used only for Firestore in Dev mode. We want to access data from this project in our dev backend server, hosted on a different cloud project. Project GCP: A GCP Project with app deployed in GAE
Python: How to Use Requests Library to Access Flask RestPlus API hosted on Google App Engine?
I built a rest api using flask restplus and I tested it using the swagger documentation, and it seems to be fully functional and working just fine. I now want to test the API using the python requests library, but I’m getting the following error: I imagine this is because I did not authorize using the credentials. I do have
Google App Engine deployment issue- main app not found
I am trying to deploy my app using Google App Engine. I have edited app.yaml to reflect the flexible environment and also gave all the app information. Below is the app.yaml file. Once the deployment is in progress, I am getting the following error Please note that App Deployed is the line in my print statement. It is getting executed.
Visual Studio Code pylint: Unable to import ‘protorpc’
I’m using pylint in Visual Studio Code to develop a Google App Engine (GAE) Cloud Endpoint API in Python. I’m unable to resolve a lint error. I don’t know what’s causing the error, but at a guess, pylint cannot find the protorpc library? The recommended fix in Troubleshooting Linting is to configure workspace settings to point to fully qualified python
PyCharm: Unreachable Code?
PyCharm is showing me that some code is unreachable within a method before the return statement is reached. I cannot help but wonder how is that even remotely possible? self.fail simply calls self.response.write(things). Update: Yeah, when I surround it with a try/catch clause, the issue is resolved… Strange. (Note that the method doesn’t always raise an exception. Answer I actually
How to generate pydoc documentation for Google Cloud Endpoints method?
I have a set of APIs that were developed using Google Cloud Endpoints. The API methods look something like this: I would like to use pydoc to generate documentation for the module that contains this method. However, when I do this, the docstring is not preserved due to the use of the endpoints.method decorator. I have seen answers to other
Python Unit test with i18 but without webapp2
I encountered a problem with unit tests when use i18 in my project. My project uses framewoks i18 and webapp2 The function uses the translation by i18. But when I test, I get the error – missing global variable request. For example it is: and I have message: I have a solution to this problem, but I do not like
A python web framework for google app engine
(Please note that this question and some of the answers are old) I want to use an existing python framework to develop an application on google appengine. It should be quick and easy to start and support test driven development practices in an easy way. Can you recommend a stack? What about django? Additional Information: There are several django ports,