How to prevent visual studio debugger from accessing the internets?

Every time I launch my .NET app (.NET 4.7, Win32, WPF) with a debugger, it takes a few seconds, then the following is logged:

(caller: 66E00728) ReturnHr(1) tid(1ee0)
80070002 The system cannot find the file specified.

Only happens when “Enable native code debugging” is checked, but unfortunately, for the current project I do need that native code debugging.

Is there a way to tell debugger to not do whatever it is doing with urlmon.dll, and work offline?

Update: wireshark says the timeout is caused by either or Both owned by Microsoft.