google cloud shell editor fails to run on cloud run emulator with error DEVINIT_REGISTER_BUILD_DEPS - gcloud

I used google cloud shell editor and created one sample app successfully and it worked ok. then a few days later, when I did the same, I started to see the error DEVINIT_REGISTER_BUILD_DEPS and can not make it work anymore. I have no idea what changed and how I can fix it. any insights?
==steps==
1.start cloud shell editor
2.create a new application (with python flask)
3.perform run on clould Run emulator
==the following messages shown==
Starting to run the app using configuration 'Cloud Run: Run/Debug Locally' from .vscode/launch.json...
To view more detailed logs, go to Output channel : "Cloud Run: Run/Debug Locally - Detailed"
Dependency check started
Dependency check succeeded
Unpausing minikube
The minikube profile 'cloud-run-dev-internal' has been scheduled to stop automatically after exiting Cloud Code. To disable this on future deployments, set autoStop to false in your launch configuration /home/yoshikiasahara/hello-world-2/.vscode/launch.json
Update initiated
Update failed with error code DEVINIT_REGISTER_BUILD_DEPS
listing files: file pattern [requirements.txt] must match at least one file
Skaffold exited with code 1.
Cleaning up...
Finished clean up.

Related

`gcloud run deploy` raises "Revision <revision_name> is not ready and cannot serve traffic."

Command
gcloud run deploy api --region=$REGION --image=$IMAGE
Logs
Deploying container to Cloud Run service [api] in project [[MASKED]] region [[MASKED]]
Deploying...
Creating Revision...........interrupted
Deployment failed
ERROR: (gcloud.run.deploy) Revision [[MASKED]] is not ready and cannot serve traffic.
I've tried to search Google Cloud documentation, but it does not mention such problem.
How to solve the "Revision is not ready and cannot serve traffic."?
Try to wait a few minutes and then just re-launch the procedure. The good old "let's retry without changing anything" worked for me! :)
EDIT: I talked with a Cloud Architect who works with me and he told me that this is the actual solution, because if you retry too quickly to restart the deploy, GCP may still have some pending operations from the previous one!
I faced the same error in Cloud Run after getting the container working correctly locally. In my case the revisions weren't showing as failing, they had a grey checkmark
and when hovering I got the message
The revision is healthy but not currently serving traffic.
I just needed to click Manage Traffic and set 100% of the traffic to a new revision
I faced this problem as well. In my case I checked "Cloud Run" section from hamburger menu of google cloud console. The "Logs" section should give you more idea about what went wrong. I was missing a python library, and adding correct python dependency in my requirements.txt solved the issue for me. Somehow my local testing went well without this issue. I hope this helps. :)
I faced with this problem, my problem is that my docker image is missing required dependency package at build stage, my Dockerfile missed some steps to copy required files for preparing to install package.
To find you problem if cloud build logs was not make sense for you, I think you should:
From gcloud console, go to service "Container Registry" > Images
Select your repository name
From the image version (maybe latest) that you want to check > more actions > show pull command > then copy that command ex: docker pull gcr.io/..
From gcloud console header > select activate cloud shell
At cloud shell terminal, pull docker images of your latest build by running "pull command" that you copied before.
Start your container from this image to see what exactly happens with your run revision

AutomationUI function test don't start by Azure Pipelines YAML

I have to run some AutomationUI functional tests from Azure DevOps Pipelines. The tests use a desktop application in WPF/Winforms. The problem is a process of application start but without UI. I run the test using YAML and tasks: VSTest#2 or PowerShell#2. I found exception in Windows Event Viewer:
The description for Event ID 0 from source VSTTExecution cannot be
found. Either the component that raises this event is not installed on
your local computer or the installation is corrupted. You can install
or repair the component on the local computer.
If the event originated on another computer, the display information
had to be saved with the event.
The following information was included with the event:
(testhost.exe, PID 13060, Thread 3)
HKEY_LOCAL_MACHINE\EnterpriseTools\QualityTools\TestTypes Key cannot
be found!
The message resource is present but the message was not found in the
message table.
I reinstalled the service as was suggested on a forum, but it still not work.
When I run the same tests from PowerShell or Command Line there is no problem.
Where could be a problem? Is there any recommended way to run functional test? I suppose the problem is between Azure DevOps Pipelines and VS test runner, because the same test was running successful by Team City or from PowerShell/Command Line

GCR Cloud Run says "Image [name] not found"

I'm trying to take my first baby steps with podman (instead of Docker) and Google Cloud Run. I've managed to build an image with a gcr.io tag and push it to Google. I then create a new service, and I can select the image in the "Select Image URL" pop-up dialog. But then the service fails to start, saying "Image [full name] not found".
I can't find anything on Google's support pages, or anywhere else. I can pull the image, I can push new versions, and they appear on the pop-up dialog. But the service still reports that they can't be found.
What am I doing wrong?
Edit in answer to DazWilkin's questions below:
Can you run the podman-created container locally using Docker?
I can't run Docker locally because it is not compatible with Fedora 31 (hence podman). But I can run it locally using podman run
Can you deploy a Docker-created container in Cloud Run?
As above: F31. However podman is supposed to be a drop-in replacement.
Is the container registry in the same project as Cloud Run?
Yes. I did have a problem with that, but I got a permissions message rather than "not found".
Have you tried deploying via gcloud rather than the console?
Yes.
$ podman push eu.gcr.io/my-project/hs-hello-world
Getting image source signatures
Copying blob c7f3d2e0289b done
Copying blob def7032cea8e done
Copying config f1c2e2615f done
Writing manifest to image destination
Storing signatures
$ gcloud run deploy --image eu.gcr.io/my-project/hs-hello-world --platform managed
Service name (hs-hello-world):
Deploying container to Cloud Run service [hs-hello-world] in project [my-project] region [europe-west1]
X Deploying... Image 'eu.gcr.io/my-project/hs-hello-world' not found.
X Creating Revision... Image 'eu.gcr.io/my-project/hs-hello-world' not found.
. Routing traffic...
Deployment failed
ERROR: (gcloud.run.deploy) Image 'eu.gcr.io/my-project/hs-hello-world' not found.
When I used a Google-built container it worked fine.
Update: 5 March 2020
In the end I just carried on with the Google build service, and it works fine. My initial wish for local builds was in large part because a build on Google was taking over half an hour (lots of Haskell libraries to import), but now I've figured out how to use staged builds and multi-processor VMs to avoid this. I appreciate the efforts of those who have tried to help, but right now it's not broke so I'm not going to try to fix it.
I had the same issue: it seems Cloud Run is picky about the kind of manifest it can pull.
By building my images with --format docker and pushing them with --remove-signatures (inspired by this issue), podman will create and push docker-style manifests to the Container Registry and everything ran smoothly!
Too bad I spent a lot of time thinking it was a lack of permissions problem
I had the same error. My issue was that I was using the docker/setup-buildx-action in a GitHub action. When this was removed, Cloud Run was happy with the resulting manifest / container image.
Thanks to #André-Breda for providing the direction.
I've been having the same issue today. I'm using buildah to create the new image. I realized that the image I used successfully yesterday was built as root. So I built the new one as root and pushed it successfully.
Wish I knew why. The images built as my username ran fine locally with rootless podman.

C++ Builder XE5 - How to turn off Deployment Manager

I apologize if this is not the right place to ask such question, but I'm at my wit's end since Embarcadero's forum won't allow me to post any question there.
I have enabled the "Deploy" feature in the C++ Builder IDE, to test out about the depending dll & bpl files of my application, when I'm done, I found myself trapped in an annoying state - I can't perform any debugging without connected to a remote pc (with their PAServer)! This is causing a HUGE problem for me as I will not be able to debug my application if I'm away from the office, i.e. I'm on a field service at my client's place or at home.
I tried deleting the deployment profile, but it just get recreated every-time I compile my project and there is a DEPLOY command upon running compiling and running the source code. I have to wait until the connection attempt to the remote pc time-out to continue testing the application by manually clicking the .exe of my application.
Is there any way to turn off the "Deploy" feature so that I can do debugging on my local machine just as before activating the "Deploy" feature?
I've found out where the profile was hiding and deleted it, now I can debug as usual.
In the Rad Studio help:
ms-help://embarcadero.rs_xe5/rad/Connection_Profile_Manager.html
On occasion, I have this same problem with DelphiXE5 (where the problem is that I forget how to get back to the default environment without losing my remote settings.)
Remote Deploy active:
The Revert option for the normal build/debug environment:
And finally, the previous Remote Deploy settings available via the same Target Platform context menu (i.e., Properties):
The Default Connection isn't something to be setup. To the contrary, it's really not a connection at all. The Revert... menu item essentially means Revert to local build & debug.

Server Google App Engine (1.8.2) at localhost failed to start

I am trying to create Dynamic Web Application in Eclipse on Google App Engine.
I have followed this tutorial exactly but whenever I Run on Server, I get the following error. I have shown both, error log and the dialog that appears when I run my project. And apparently there is no search result after Googling this error. Any help would be appreciated in this regard. Thanks.
UPDATE:
Point to note here is that if I use the tutorial available here then the project runs fine. The difference is that This way I create new project by clicking the New Web Application Project button in the toolbar:
It is because your launch configuration file is corrupt.
location: WORKSPACE/.metadata/.plugins/org.eclipse.debug.core/.launches.
All you need to do to solve this problem is to delete the existing launch configuration (in Run > Run configurations)
More precisely: Run > Run configurations > Web Application > right click in your project's name > Delete