Closed thoffmann-fms closed 2 years ago
It's likely that Edge Chromium WebView was now installed and Office has started using it. Debugging it requires a different debug extension. The latest Yo Office projects have updates for this, or see https://github.com/OfficeDev/Office-Addin-TaskPane.
I've had Chromium Edge installed for months and been debugging just fine. That's why F12 works (legacy Edge didn't launch anything when one pressed F12 in the Add-In pane).
It's not whether the Edge Chromium browser is installed, but the "Microsoft Edge WebView2 Runtime". You can go to Control Panel, Uninstall a program, and search for "webview2" and see if this is listed. I suspect this was installed recently for you as part of Office updates.
The VS Code launch.json will need to use "type": "edge" instead of "type": "office-addin". See https://github.com/OfficeDev/Office-Addin-TaskPane/blob/master/.vscode/launch.json#L28.
WebView2 has been installed for several months. Also legacy Edge uses Microsoft Edge DevTools Preview (which has not been showing any available targets for several months), not the port 9222 accessed via VS Code. Something in Outlook has broken since there isn't anything listening to port 9222 (or 9229). Also if you look at the launch.json I pasted in the original comment you'll see it's set to type=edge.
Debugging in Outlook is magically working correctly today. New Outlook version since I originally opened this ticket though.
Was
Microsoft® Outlook® for Microsoft 365 MSO (16.0.14326.20164) 64-bit
Now
Microsoft® Outlook® for Microsoft 365 MSO (16.0.14326.20324) 64-bit
A week or two ago I could debug Outlook Add-Ins but since my last Outlook 365 update that no longer works. Office no longer prompts me with a Ok/Cancel message about starting a debugger.
Neither Port 9222 nor 9229 are being listened to.
{ "version": "0.2.0", "configurations": [ { "name": "Debug Office Add-in (Edge Chromium)", "type": "edge", "request": "attach", "useWebView": "advanced", "port": 9229, "timeout": 100000, "webRoot": "${workspaceRoot}" } ] }
I am able to run F12 and debug using the Edge DevTools.
C:\Windows\System32>netstat -an | find "92" TCP 0.0.0.0:16992 0.0.0.0:0 LISTENING TCP 10.0.0.184:49206 10.0.0.1:80 TIME_WAIT TCP 10.0.0.184:49213 52.168.112.81:443 TIME_WAIT TCP 10.0.0.184:49238 20.190.154.18:443 TIME_WAIT TCP 10.0.0.184:49251 52.168.112.83:443 TIME_WAIT TCP 10.0.0.184:49274 20.190.154.18:443 TIME_WAIT TCP 10.0.0.184:49287 52.168.112.83:443 TIME_WAIT TCP 10.0.0.184:56400 104.192.142.6:443 ESTABLISHED TCP 10.0.0.184:64392 3.234.79.72:80 ESTABLISHED TCP 127.0.0.1:12080 127.0.0.1:60927 ESTABLISHED TCP 127.0.0.1:49261 127.0.0.1:49673 TIME_WAIT TCP 127.0.0.1:60926 127.0.0.1:60928 ESTABLISHED TCP 127.0.0.1:60927 127.0.0.1:12080 ESTABLISHED TCP 127.0.0.1:60928 127.0.0.1:60926 ESTABLISHED TCP 192.168.16.1:139 0.0.0.0:0 LISTENING TCP [::]:16992 [::]:0 LISTENING UDP 0.0.0.0:65292 : UDP 127.0.0.1:60592 : UDP 127.0.0.1:60928 : UDP 192.168.16.1:67 : UDP 192.168.16.1:68 : UDP 192.168.16.1:137 : UDP 192.168.16.1:138 : UDP 192.168.16.1:1900 : UDP 192.168.16.1:2177 : UDP 192.168.16.1:60593 : UDP [2601:589:8480:6400:68ef:492a:30d1:4b54]:2177 :