microsoft / vscode-azurestaticwebapps

Azure Static Web Apps extension for VS Code
https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-azurestaticwebapps
MIT License
88 stars 35 forks source link

The breakpoint is not hit when debugging the angular-basic project with C# function #625

Open v-ruizh opened 2 years ago

v-ruizh commented 2 years ago

OS: All Build Version: 20220228.4

Repro Steps:

  1. Clone https://github.com/staticwebdev/angular-basic -> Open the project in VS Code.
  2. Open VS Code terminal and run "npm install" -> Go to the "Run and Debug" menu -> Select the "Show all automatic debug configurations." -> Select "Azure Static Web Apps…" -> Select "SWA: Run angular-basic".
  3. Create a HTTP endpoint named "message" with C# language and the default namespace.
  4. Click "Overwrite" button in the prompt dialog. image
  5. Set a breakpoint in message.cs file.
  6. Go to the "Run and Debug" view, select the "SWA: Run angular-basic" option to debug.
  7. Navigate to "http://localhost:4280/api/message" in the Chrome window.
  8. Check whether the breakpoint is hit or not.

Expect: The breakpoint is hit.

Actual: The breakpoint is not hit.

More Info: This issue does not reproduce when adding a HTTP endpoint named "message" with TypeScript/JavaScript/Python.

alexweininger commented 2 years ago

@v-ruizh What is the output of func --version and dotnet --list-runtimes? And can you verify that this reproduces on all operating systems (Windows specifically)? We're only able to reproduce this issue on macOS.

v-ruizh commented 2 years ago

@alexweininger Verified this bug with Function and Static Web Apps extension RC builds installed on Windows and Linux OS, it is no longer reproduce. The output of func --version and dotnet --list-runtimes: image

v-ruizh commented 2 years ago

Verified this issue on the build 20220616.1, it just reproduces when adding a HTTP endpoint named "message" with C# and Python languages.