azure-dev icon indicating copy to clipboard operation
azure-dev copied to clipboard

Server error when Azure Dev Deploy finished

Open v-jiaodi opened this issue 3 years ago • 4 comments

Describe the issue: Server error when Azure Dev Deploy finished.

Repro Steps: Run command: bash ./test-templates.sh -c false -t <template_name> -b pr/551.

Error Message:

image

Through investigation, we found that it was caused by API service exception

image

image

Environment: OS: Windows desktop, Linux Desktop, WSL ,Mac ,Codesapce and DevContainer. Templates: https://github.com/Azure-Samples/todo-nodejs-mongo-swa-func https://github.com/Azure-Samples/todo-python-mongo-swa-func Branch: pr/551

Expected behavior: The api server is normal, and e2e test is pass.

@jongio for notification.

v-jiaodi avatar Oct 11 '22 09:10 v-jiaodi

@jongio @madebygps did we make any changes to other templates as part of #551? any changes in your PR could cause this?

rajeshkamal5050 avatar Oct 11 '22 16:10 rajeshkamal5050

Yes, I will investigate.

jongio avatar Oct 11 '22 17:10 jongio

@jongio We do the manual test about template (todo-python-mongo), also encountered the same error when Azure Dev Deploy finished. It is a probabilistic error.

Error: image

Environment: OS: Windows desktop Templates: https://github.com/Azure-Samples/todo-python-mongo Branch: pr/892 Azd version: azd version 0.3.0-beta.3-daily.1921004 (commit e52ea013fede3560b90f4cf9d0a8e6d6ceac376a)

v-xuto avatar Oct 17 '22 10:10 v-xuto

Please try again with main. If it fails, please leave it in failed state and provide me and @weikanglim with a link to the env.

jongio avatar Oct 20 '22 17:10 jongio

@jongio - We have tried again with main, it is still unstable. When we execute the command bash ./test-templates.sh -c false -t todo-python-mongo -l eastus2, the playwright test failed. At this point, when we click the api site, it reported Application Error. After a period of time, the api service can be deployed successfully, and the error will not occur again when playwright test is executed again.

In summary, the error was caused by the api service is not deployed successfully yet, the playwright test is run first.

zedy-wj avatar Oct 21 '22 04:10 zedy-wj

Can you try with a different region and see if you get the same error?

jongio avatar Oct 21 '22 18:10 jongio

@jongio - We have tried with region East US, and get the same error. This time it was due to a failed deployment, you can reach from this link. Template: https://github.com/Azure-Samples/todo-python-mongo Branch: main azd version: 0.3.0-beta.3-daily.1937328 (commit d18003a6799b545e4050544f9fa05f1eaedb0948)

zedy-wj avatar Oct 24 '22 06:10 zedy-wj

The detector was extremely helpful. I found the following errors related to the docker container crashing:

File "<frozen importlib._bootstrap>", line 973, in _find_and_load_unlocked
2022-10-24T03:24:54.032196245Z ModuleNotFoundError:
No module named 'uvicorn'2022-10-24T03:24:54.032199945Z ]

weikanglim avatar Oct 24 '22 18:10 weikanglim

What do you mean by the detector?

jongio avatar Oct 25 '22 13:10 jongio

Could be related: https://github.com/Azure/azure-dev/issues/932

jongio avatar Oct 25 '22 13:10 jongio

Not seeing these template failures in the pipelines. Might be a temporary region issue. Reopen if you see again.

rajeshkamal5050 avatar Oct 25 '22 16:10 rajeshkamal5050

@rajeshkamal5050, @jongio - In today's test, the issue persists and occurs at a high rate.

OS: Windows desktop. azd version: azd version 0.3.0-beta.6-pr.1947898 (commit a7b9ee6038c4ecbe8ddda4c0ba1acbd2ec208fc8) branch: pr/996 templates: https://github.com/azure-samples/todo-python-mongo https://github.com/azure-samples/todo-csharp-cosmos-sql https://github.com/Azure-Samples/todo-csharp-sql https://github.com/Azure-Samples/todo-java-mongo https://github.com/azure-samples/todo-nodejs-mongo

The latest error: image

zedy-wj avatar Oct 27 '22 09:10 zedy-wj

Fixed with #996

jongio avatar Nov 01 '22 17:11 jongio