google-app-engine

Can't upload large files to Python + Flask in GCP App Engine

只愿长相守 提交于 2021-01-28 02:07:11
问题 UPDATE: (5/18/2020) Solution at the end of this post! I'm attempting to upload big CSV files (30MB - 2GB) from a browser to GCP App Engine running Python 3.7 + Flask, and then push those files to GCP Storage. This works fine on local testing with large files, but errors out immediately on GCP with a " 413 - Your client issued a request that was too large " if the file is larger than roughly 20MB. This error happens instantly on upload before it even reaches my custom Python logic (I suspect

After upgrading to Angular8, AppEngine is serving scripts with the incorrect mime-type

一个人想着一个人 提交于 2021-01-28 01:41:18
问题 There seems to be a change if not a bug to how Angular8 packages up index.html that is breaking my deployment. The scripts at the bottom of the index.html in the dist folder no longer have type="text/javascript" <script src="runtime-es2015.b1e01c6054a9feffbeda.js" type="module"></script> <script src="polyfills-es2015.dd0ef0c762416a11ccfe.js" type="module"></script> <script src="runtime-es5.b1e01c6054a9feffbeda.js" nomodule></script><script src="polyfills-es5.ad2e20378bba1e661425.js" nomodule>

Google Drive API - How to work with the domain-wide service account and get all document list from domain

旧城冷巷雨未停 提交于 2021-01-27 21:18:51
问题 I was trying to use the service account of my App to access to all documents of all users in my domain. I was following these instructions: https://developers.google.com/drive/delegation But it didn't work. Could you please help me out on this?? Here is the problematic line of code GoogleCredential credential = new GoogleCredential.Builder() .setTransport(TRANSPORT) .setJsonFactory(jsonFactory) .setServiceAccountId("SERVICE_ACCOUNT_EMAIL") .setServiceAccountPrivateKeyFromP12File( new java.io

Restlet Getting HTTP Status code 204 instead of 200

梦想与她 提交于 2021-01-27 20:04:29
问题 For the 1st request, I get the JSON response. From the next request onwards I start getting this log and HTTP Status Code 204, even though the ServerResource is successfully returning a representation org.restlet.engine.adapter.ServerAdapter commit WARNING: A response with an unavailable and potentially non empty entity was returned. Ignoring the entity for resource http://localhost:8888/xyz?abc=def Application class for wiring routes @Override public Restlet createInboundRoot() { router =

GAE App Engine Websocket clients are disconnected after 1 hour

时光怂恿深爱的人放手 提交于 2021-01-27 19:45:30
问题 I have a simple Websocket server deployed to AppEngine, after exactly 1 hour clients are disconnected with error code 1006, I believe this is happening because of the nginx load balancer, I have tried changing nginx-app.conf, but it didn't help proxy_send_timeout 7d; proxy_read_timeout 7d; My server is sending ping / pong frames every 10 seconds, so inactivity is out of the question. The official GAE documentation states this: "WebSockets are always available to your application without any

How to get WeasyPrint working with Google App Engine

泪湿孤枕 提交于 2021-01-27 19:15:57
问题 I'm new to GAE, WeasyPrint and Python. I realise that WeasyPrint relies on quite a few dependences. I have had a look at the install documentation for Windows. But I cant seem to figure out how I would get it working on GAE. Is there no way to download an version with all the dependencies included and just copy it to my project folder? 回答1: Its not possible to run WeasyPrint directly on appengine. You should always read the docs on the dependencies. WeasyPrint is dependent on cairo and pango

How to deploy Google app engine application through the deployment manager ? Is it possible to do it

眉间皱痕 提交于 2021-01-27 17:31:03
问题 I am deploying all my application to Appengine. I found a "Development" tool in the Developer Console and configured it to sync my Appengine project files. I utilized the online editing feature to edit an appengine project file through the Development tool. I made changes and committed the code. So I want to know whether it is possible to use deployment manager for deploying the app engine services?? Can someone help me on how I can use the Deployment Manager to deploy the changes I made

GCP Cloud build ignores timeout settings

旧时模样 提交于 2021-01-27 14:15:53
问题 I use Cloud Build for copying the configuration file from storage and deploying the app to App Engine flex . The problem is that the build fails every time when it lasts more than 10 minutes. I've specified timeout in my cloudbuild.yaml but it looks like it's ignored. Also, I configured app/cloud_build_timeout and set it to 1000. Could somebody explain to me what is wrong here? My cloudbuild.yaml looks in this way: steps: - name: gcr.io/cloud-builders/gsutil args: ["cp", "gs://myproj-dev

How to install Python3 in Google Cloud Platform for a Node app

久未见 提交于 2021-01-27 14:12:35
问题 I'm using google cloud platform for my nodejs app. Problem, after deploying the app i have access to python2.7 but not to the version 3. This one seems to be missing in the usr/bin folder. const spawn = require("child_process").spawn; spawn('python'); // working spawn('/usr/bin/python3'); // not working spawn('python3'); // not working Error: spawn python3 ENOENT I used fs module to display the usr/bin folder : ... pygettext2.7 python python2 python2.7 pyversions ... Any idea how can I

__call__() missing 1 required positional argument: 'send' FastAPI on App Engine

喜欢而已 提交于 2021-01-27 13:02:30
问题 When trying to host an API on App Engine, the following error keeps coming up. The program used to run on Flask which was working but very slow. Error: "Traceback (most recent call last): File "/env/lib/python3.7/site-packages/gunicorn/workers/sync.py", line 134, in handle self.handle_request(listener, req, client, addr) File "/env/lib/python3.7/site-packages/gunicorn/workers/sync.py", line 175, in handle_request respiter = self.wsgi(environ, resp.start_response) TypeError: __call__() missing