microsoft / microsoft/vscode-azurestaticwebapps

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

Open
#625 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

AT-CTI debugging P1
Dominant language
TypeScript
Stars
99
Forks
39
Avg merge
3d 7h
Merged PRs (30d)
2

Description

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.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with the angular-basic project using the documented Run and Debug configuration, then inspect the generated message.cs endpoint and its C# debugging setup. Compare the behavior with the TypeScript, JavaScript, and Python endpoints. Done means a breakpoint in message.cs is hit when requesting http://localhost:4280/api/message.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, csharp, typescript, vscode
Domain
developer-experience, devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.