You can see one of two possible error messages:
- Coverage session finished with errors: Can't set event mask (COM error 0x80131377).
- Coverage session finished with errors: Can't profile the application because the host protection is applied. Probably it relates with Microsoft SQL…
The cause of the errors is host protection:
- dotCover gets the following result during profiler initialization when it asks CLR for the required callbacks: CORPROF_E_INCONSISTENT_FLAGS_WITH_HOST_PROTECTION_SETTING