QTAgent Hanged in between test execution RRS feed

  • Question

  • I am using VSTS 2017 with framework .net framework 4.7.1

    I have setup of execution of CodedUI test using VSTestconsole utility, where we are picking number of test cases on the basis of test category. but from last few month facing issue that in between QT agent hanged or stop working so test cases execution neither proceed nor stop for many days.

    And i observed that QT agent is taking 97% of CPU utilization, not  sure why that much of CPU utilization is taken by QTagent.

    In event log also i getting following error 

    The description for Event ID 0 from source VSTTExecution cannot be found. Either the component that raises this event is not installed on your local computer or the installation is corrupted. You can install or repair the component on the local computer.

    If the event originated on another computer, the display information had to be saved with the event.

    The following information was included with the event: 

    (QTAgent32_40.exe, PID 25408, Thread 34) DataCollectorNotificationsHelper.RaiseTestFailedEvent: Exception occured raising the test failed event: System.Runtime.Serialization.SerializationException: Unable to find assembly 'SXA.Framework, Version=, Culture=neutral, PublicKeyToken=null'.

    Server stack trace: 
       at System.Runtime.Serialization.Formatters.Binary.BinaryAssemblyInfo.GetAssembly()
       at System.Runtime.Serialization.Formatters.Binary.ObjectReader.GetType(BinaryAssemblyInfo assemblyInfo, String name)
       at System.Runtime.Serialization.Formatters.Binary.ObjectMap..ctor(String objectName, String[] memberNames, BinaryTypeEnum[] binaryTypeEnumA, Object[] typeInformationA, Int32[] memberAssemIds, ObjectReader objectReader, Int32 objectId, BinaryAssemblyInfo assemblyInfo, SizedArray assemIdToAssemblyTable)
       at System.Runtime.Serialization.Formatters.Binary.__BinaryParser.ReadObjectWithMapTyped(BinaryObjectWithMapTyped record)
       at System.Runtime.Serialization.Formatters.Binary.__BinaryParser.ReadObjectWithMapTyped(BinaryHeaderEnum binaryHeaderEnum)
       at System.Runtime.Serialization.Formatters.Binary.__BinaryParser.Run()
       at System.Runtime.Serialization.Formatters.Binary.ObjectReader.Deserialize(HeaderHandler handler, __BinaryParser serParser, Boolean fCheck, Boolean isCrossAppDomain, IMethodCallMessage methodCallMessage)
       at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Deserialize(Stream serializationStream, HeaderHandler handler, Boolean fCheck, Boolean isCrossAppDomain, IMethodCallMessage methodCallMessage)
       at System.Runtime.Remoting.Channels.CrossAppDomainSerializer.DeserializeObject(MemoryStream stm)
       at System.Runtime.Remoting.Messaging.SmuggledMethodCallMessage.FixupForNewAppDomain()
       at System.Runtime.Remoting.Channels.CrossAppDomainSink.DoDispatch(Byte[] reqStmBuff, SmuggledMethodCallMessage smuggledMcm, SmuggledMethodReturnMessage& smuggledMrm)
       at System.Runtime.Remoting.Channels.CrossAppDomainSink.DoTransitionDispatchCallback(Object[] args)

    Exception rethrown at [0]: 
       at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
       at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
       at Microsoft.VisualStudio.TestTools.TestTypes.Unit.DataCollectorNotificationsHelper.RaiseTestFailedEvent(ITestElement test, TestCaseFailureType failureType)
       at Microsoft.VisualStudio.TestTools.TestTypes.Unit.DataCollectorNotificationsHelper.RaiseTestFailedEvent(TestCaseFailureType failureType)

    the message resource is present but the message is not found in the string/message table

    Need help to identify possible cause of hanging QTAgent.


    Tuesday, January 7, 2020 6:55 AM

All replies

  • Hi Priyanka Patodia,

    Welcome to MSDN forum.

    Did you run 3rd application on agent machine? Please try to close it, then re-run Test Agent.

    Not sure if the agent has been damaged, you could go to Visual Studio installer to repair agent,

    In addition, you could also follow this thread to run your visual studio as safe mode, to check if it could work.

    Any feedback will be expected.

    Best Regards,


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact

    Tuesday, January 7, 2020 9:26 AM