wewedroid
wewedroid

Reputation: 68

Unable to watch variables during debug of T4 templates after updating to Visual Studio 2015 Update 2

After Updating Visual studio 2015 from VS2015 Update 1 to Update 2. I can no longer watch or inspect variable values during T4 template debugging

As you can see, the watched variables are not found in the current context. This was previously working in Visual Studio 2015 update 1

Here is a Screenshot in visual studio while debugging a T4 template:

Screenshot in visual studio while debugging a T4 template

Upvotes: 4

Views: 741

Answers (2)

Patrick Nelson - MSFT
Patrick Nelson - MSFT

Reputation: 3170

This looks like a bug that was introduced in Visual Studio 2015 Update 2. Essentially the debugger is unable to inspect local variables in dynamic modules and it may be causing the behavior you are seeing. We released a hotfix for it today. You can download the patch here. Documentation for the patch is here. Let me know if the patch does not fix your particular scenario.

Thanks!

-Patrick Nelson

Upvotes: 3

bunnyWrote
bunnyWrote

Reputation: 56

I had the same trouble. Try this "Debug->Options->Debugging:General-> set checkbox on the Use Managed Compatibility Mode".

Upvotes: 4

Related Questions