Problems with launching via XPC. XPC error : Connection interrupted

Hi,


I am getting this Xcode error "Problems with launching via XPC. XPC error : Connection interrupted", while debug as root. Though i have not use XPC or XPC framework in my code.

I have not uploaded my application on App store.

when i start xcode and run very first time it runs properly but when i stop and run it again it gives me this error.

I am using macOS Mojave and Xcode version 11.1


Error Details -


Details


Could not launch “test2”

Domain: IDEDebugSessionErrorDomain

Code: 3

Failure Reason: Problems with launching via XPC. XPC error : Connection interrupted

--

Problems with launching via XPC. XPC error : Connection interrupted

Domain: IDEDebugSessionErrorDomain

Code: 3

--


I am unable to understand what is the exact issue.

Appreciate if anyone can help.


Thanks.