Azure / Azure/azure-functions-core-tools
func.exe Processes Not Ending And Holding On To Ports
- Dominant language
- C#
- Stars
- 1.5k
- Forks
- 498
- Avg merge
- 4d 20h
- Merged PRs (30d)
- 14
Description
### Version
Core Tools Version: 4.0.6821
Function Runtime Version: 4.1036.1.23224
### Description
After running a function locally in VS Code (whether debugging or not), an iteration of stopping, editing and running again often shows multiple of these warnings in the terminal window:
`warning MSB3231: Unable to remove directory "\obj\Debug\net8.0\WorkerExtensions"`
and even after killing all terminals, running
`Get-Process -Id (Get-NetTCPConnection -LocalPort 7071).OwningProcess`
often shows a func.exe still running:
```
NPM(K) PM(M) WS(M) CPU(s) Id SI ProcessName
------ ----- ----- ------ -- -- -----------
242 61.06 215.07 3.62 29888 5 func
```
and even closing VS Code doesn't always work...
### Steps to reproduce
see description
Contributor guide
Research direction
No source file or test is named. Start by reproducing the VS Code stop, edit, and rerun sequence, then inspect the func.exe process owning port 7071 and the MSB3231 warning. Done means the local function process exits when stopped and repeated runs no longer leave processes holding the port or prevent WorkerExtensions cleanup.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, powershell, vscode
- Domain
- cli, devtools
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100