Bad Request when using C# XML comment completion #169262
Replies: 6 comments 3 replies
-
|
This just started happening today to all of my instances of VS 2022 Enterprise (17.14.11) as well. Only seems to be happening to the XML comment completion. |
Beta Was this translation helpful? Give feedback.
-
|
Hi @KuroiLight, From what you’ve described, this isn’t an issue with your C# code or XML documentation syntax — it’s a connectivity or request-handling problem between Visual Studio’s GitHub Copilot integration and the Copilot API. The “Bad Request” and proxy-related hints in your logs suggest that something in the environment is either interrupting the request or changing its format before it reaches GitHub’s servers. Since this only happens when trying to auto-generate XML summaries (///), it’s likely tied to the specific Copilot feature for comment completion rather than the general coding suggestions. You’ve already tried resetting Visual Studio, repairing it, signing out and back in, and clearing cache files, which rules out many local configuration issues. The fact that another user reported the same behavior starting on the same day indicates that this might be a service-side change or regression in Copilot’s XML comment handling. In those cases, local fixes are often ineffective until the service or extension is updated. That said, it’s still worth confirming there’s no proxy, firewall, or security software interfering with HTTPS traffic to https://api.githubcopilot.com. If you’re behind a proxy, check that the HTTPS_PROXY environment variable is set correctly for your system and that Visual Studio can use it. If no proxy is involved, you might try temporarily disabling strict network filtering or antivirus HTTPS inspection to see if it resolves the request failure. If the issue persists after confirming network conditions, the next best step is to file a bug report through Visual Studio’s Help → Send Feedback → Report a Problem tool, referencing the error logs you’ve captured. This will give the Copilot and Visual Studio teams the context they need to reproduce and address the problem. In the meantime, you can still manually write XML documentation or use general Copilot suggestions by prompting it in an inline comment rather than relying on the /// shortcut. Best of luck! |
Beta Was this translation helpful? Give feedback.
-
|
Also worth mentioning that this issue happens to both my desktop and work laptop that are in 2 different locations which have completely separate internet egresses. One is behind an enterprise network firewall and the other is at home on a residential network with absolutely no proxies or firewalls. And both starting displaying the exact same logs @KuroiLight posted to a T. |
Beta Was this translation helpful? Give feedback.
-
|
I can confirm I'm getting this as well. I was able to add a ticket here: https://developercommunity.visualstudio.com/t/Error-creating-C-XML-Documentation-with/10949548 |
Beta Was this translation helpful? Give feedback.
-
|
Microsoft confirmed that this was fixed. Huzzah! :) |
Beta Was this translation helpful? Give feedback.
-
|
Well, this was fixed and then 17.14.13 was released and now it sometimes works and sometimes doesn't. I don't see the same exceptions in the copilot output window, it just doesn't seem to be reliably triggering the AI doc comments feature. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Select Topic Area
Question
Copilot Feature Area
Visual Studio
Body
Having a issue when trying to generate C# xml summaries (<summary>)
e.g. typing /// causes the [...] to appear for a second then I get the error below.
I tried:
Beta Was this translation helpful? Give feedback.
All reactions