Skip to content
This repository has been archived by the owner on Oct 11, 2023. It is now read-only.

On editing a file same is not reflected on the cloud. #306

Open
nitinkapur opened this issue Apr 4, 2020 · 3 comments
Open

On editing a file same is not reflected on the cloud. #306

nitinkapur opened this issue Apr 4, 2020 · 3 comments

Comments

@nitinkapur
Copy link

I created a simple project with dotnet. Using "dotnet new mvc -n sampleproject" command in VSCode.
I had an AKS cluster running and connected my project using command "az aks use-dev-spaces -g kubernetes_testing -n testing" I connected to the "default" dev space and then prepped it by using "azds prep --enable-ingress" once that was dons "azds up" was used to run the container on cloud.

Everything goes well I can debug from the cloud. But whenever I make any changes to the index.cshtml page while azds is running the same is not reflected in the cloud running instance unless I stop and again run "azds up".

The demos I saw did show that changing any files auto deploys those files and is reflected in the cloud in their dev space. The error I am getting is below. but debug does run as it is supposed to be.

This files is not ignored and it does try to sync the file but fails.

2020-04-03T22:12:29.5751491Z | SDK | TRACE | Event: WatchSyncUpdater-SyncWorkspace {"properties":{"result":"Succeeded"},"metrics":{"duration":455.0}}
2020-04-03T22:12:43.4974796Z | SDK | WARNG | EnsureDevHostAgentConnectionAsync: container cannot be reached after retry.
2020-04-03T22:12:43.4984136Z | SDK | WARNG | File synchronization failed
2020-04-03T22:12:43.4992602Z | SDK | TRACE | Event: WatchSyncUpdater-SyncUpdateCode {"properties":{"result":"Succeeded"},"metrics":{"duration":14384.0}}
2020-04-03T22:12:52.7808278Z | SDK | WARNG | Channel exception on read operation for service log
2020-04-03T22:12:52.7834398Z | SDK | WARNG | Lost connection with the server!: System.Net.WebSockets.WebSocketException The remote party closed the WebSocket connection without completing the close handshake

@daniv-msft
Copy link
Collaborator

Thank you for reporting this issue, and sorry you encountered it.
Another customer reported a similar issue recently in another repository (MicrosoftDocs/azure-docs#51000), so the root cause is probably the same.

I have been able to reproduce the issue you mention when debugging a service running on .NET Core 3.1.
However, I couldn't reproduce the issue on a .NET Core 2.2 service.
Could you please confirm that you see the same behavior?

Also, even though my updates were not visible in the deployed service for .NET Core 3.1, I didn't get the "File synchronization error" you reported. Is it possible that you were you running "azds up" in another command prompt while debugging in VS Code?

@nitinkapur
Copy link
Author

Yes, I get file synchronization error on .Net Core 3.1 only. I was using "azds up" command in the VSCode terminal while trying it.

@daniv-msft
Copy link
Collaborator

Thanks for your reply! When you debug in VS Code, our extension takes care of running azds up for you, so that you don't have to do it yourself. Running both VS Code Dev Spaces debugging and azds up in parallel will create this "File synchronization error".

Regarding the live edits not reflected on .NET Core 3.1, this is a bug on our side I'm investigating. I'll update this thread once I have a fix.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants