debugger is looking for executioncontext.cs, how to fix? debugger is looking for executioncontext.cs, how to fix? json json

debugger is looking for executioncontext.cs, how to fix?


A debug setting had been changed somehow and enabling the Just My Code setting returned it back to normal managed exception throwing. To do so, go to

Debug > Options... > Debugging > General > Enable Just My Code


Solution for MAC :

See the left top menu options on Visual Studio (2017), which display two items 1. Debug 2. Release . Just flip it to "Release" and that should resolve the issue. By mistake it switched to debug.

And clean your caches as well on Mac, you may follow below steps :

  1. Quit out of any actively open Mac apps
  2. Go to the Finder in Mac OS
  3. Hold down the SHIFT key (in Sierra) or OPTION / ALT key (Earlier) and pull down the “Go” menu in the Finder
  4. Choose “Library” from the Go menu options
  5. Once inside the Library folder, find and open the “Caches” folder
  6. Clear the caches


For me Just My Code was disabled, but this was because I had a different problem before where I could not debug any of my unit tests. It would go to run the test then exit for no apparent reason.

However, the reason, I found out, on closer inspection of the error referred to by OP, was that I was trying to debug in RELEASE mode! Once I changed to DEBUG mode it worked fine.I enabled Just My Code again after and it was still fine.