vstestconsole.exe: Data collection : Unable to find a datacollector with friendly name 'CatchEventsCollector' - visual-studio-2019

I'm using a custom Datacollector for vstestconsole.exe (Version 14.0.25420.1) on a Windows Server 2012 R2 Standard and it works perfectly.
After migrating to Windows Server 2019 and vstestconsole.exe (Version 16.11.0) I still execute the same command:
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\CommonExtensions\Microsoft\TestWindow>vstest.console.exe C:\VS\FFBE\020_Test\FW\Ffbe.Test\TestKonsole\bin\Debug\MyTest.dll /logger:trx
/Settings:C:\VS\Settings.runsettings
/tests:TF01_G,
/Diag:E:\Temp\log.txt
And I keep on getting the following error:
Data collection : Unable to find a datacollector with friendly name 'CatchEventsCollector'.
Data collection : Could not find data collector 'CatchEventsCollector'
My runsettings-file looks like this:
<?xml version="1.0" encoding="utf-8"?>
<RunSettings>
<MSTest>
<DeleteDeploymentDirectoryAfterTestRunIsComplete>false</DeleteDeploymentDirectoryAfterTestRunIsComplete>
</MSTest>
<RunConfiguration>
<ResultsDirectory>e:\test\Framework</ResultsDirectory>
</RunConfiguration>
<DataCollectionRunSettings>
<DataCollectors>
<DataCollector friendlyName="CatchEventsCollector" uri="datacollector://TestCompany/FfbeTestFramework/1.0" assemblyQualifiedName="Datacollector.CatchEventsCollector, Datacollector, Version=1.0.0.0, Culture=neutral" />
</DataCollectors>
</DataCollectionRunSettings>
</RunSettings>
If I replace my custom-Datacollector in the runsettings e.g. with the onboard-VideoRecorder-Datacollector (), vsTestconsole is able to find the collector.
I named my custom-Datacollector Datacollector.dll and implemented following the official MS-instructions: Implementing a custom Data Collector
I placed my Datacollector.dll in the folder 'C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\Extensions\TestPlatform\Extensions'. According to the vstestconsole-diagnostics-log it is being found and loaded:
TpTrace Verbose: 0 : 15416, 8, 2023/01/18, 18:41:25.902, 4593946638372, testhost.net48.x86.exe, TcpClientExtensions.MessageLoopAsync: NotifyDataAvailable remoteEndPoint: 127.0.0.1:8265 localEndPoint: 127.0.0.1:8266
TpTrace Information: 0 : 15416, 8, 2023/01/18, 18:41:25.906, 4593946674455, testhost.net48.x86.exe, TestRequestHandler.OnMessageReceived: received message: (TestExecution.Initialize) -> [
"C:\\VS\\FFBE\\020_Test\\FW\\Ffbe.Test\\TestKonsole\\bin\\Debug\\NUnit3.TestAdapter.dll",
"C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\\Common7\\IDE\\Extensions\\TestPlatform\\Extensions\\Datacollector.dll",
"C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\\Common7\\IDE\\Extensions\\TestPlatform\\Extensions\\Microsoft.Cci.dll",
Still I keep getting the error that a data Collector with the friendlyName 'CatchEventsCollector' can not be found.
I'm stuck on this issue for a week now.
I'd appreciate any hint.
Thank you in advance

Related

Jenkins Windows Slave setup using Winsw not working

Using this info https://hayato-iriumi.net/2019/05/23/how-to-install-jenkins-slave-as-windows-service/ we are setting up the Jenkins Slave on Windows server. Jenkins agent start from command line. but when we start from Windows service, its giving below error message? How to resolve this error message?
Service cannot be started. System.IO.InvalidDataException: Attribute <className> is missing in configuration XML
at winsw.Util.XmlHelper.SingleAttribute[TAttributeType](XmlElement node, String attributeName)
at winsw.Extensions.WinSWExtensionDescriptor.FromXml(XmlElement node)
at winsw.Extensions.WinSWExtensionManager.LoadExtension(String id)
at winsw.Extensions.WinSWExtensionManager.LoadExtensions()
at winsw.WrapperService.OnStart(String[] args)
at System.ServiceProcess.ServiceBase.ServiceQueuedMainCallback(Object state)
xml file we have
<service>
<id>JenkinsSlave</id>
<name>Jenkins agent</name>
<description>This service runs an agent for Jenkins automation server.</description>
<executable>c:\java\jdk-11\bin\java.exe</executable>
<arguments>-Xrs -jar "c:\jenkins\slave.jar" -jnlpUrl https://jenkinsmaster/jenkins/computer/slave01/slave-agent.jnlp -secret a4b5b4ddfd34a016cd3a8eb94cbe8f908613e33a66db5fa6f5f43a080aea3116 -workDir=c:\jenkins</arguments>
<workingdirectory>c:\jenkins</workingdirectory>
<logmode>rotate</logmode>
<onfailure action="restart">
<download from="https://jenkinsmaster/jenkins/jnlpJars/slave.jar" to="c:\jenkins\slave.jar">
<extensions>
<extension enabled="false" classname="winsw.Plugins.RunawayProcessKiller.RunawayProcessKillerExtension" id="killOnStartup">
<pidfile>c:\jenkins\jenkins_agent.pid</pidfile>
<stoptimeout>5000</stoptimeout>
<stopparentfirst>false</stopparentfirst>
</extension>
</extensions>
</download>
</onfailure>
</service>
Thanks
There are some errors in the sample "Jenkins-Slave.xml" that is presented at the linked web page (which yours is apparently based on). It has all elements and attributes named in lowercase, but actually some of them should be mixed case (as can be seen by the error message that it doesn't find attribute className).
Try this one instead:
<service>
<id>YourJenkinsSlaveServiceId</id>
<name>Your Jenkins Slave Service Name</name>
<description>This service runs an agent for Jenkins automation server.</description>
<executable>C:\Program Files\Java\JRE8\bin\java.exe</executable>
<arguments>-Xrs -jar "%BASE%\slave.jar" -jnlpUrl http://YourJenkinsServer:8080/computer/YourNodeName/slave-agent.jnlp -secret YourSecretStringConsistingOfHexadecimalCharacters -workDir=C:\YourNodeWorkDir</arguments>
<logmode>rotate</logmode>
<onfailure action="restart" />
<download from="http://YourJenkinsServer:8080/jnlpJars/agent.jar" to="%BASE%\slave.jar"/>
<extensions>
<extension enabled="true" className="winsw.Plugins.RunawayProcessKiller.RunawayProcessKillerExtension" id="killOnStartup">
<pidfile>%BASE%\jenkins_agent.pid</pidfile>
<stopTimeout>5000</stopTimeout>
<stopParentFirst>false</stopParentFirst>
</extension>
</extensions>
</service>
This is from a more detailed explanation of how to install an agent as a Windows service which I have given in this answer.
I too has the same issue similarly..
System.IO.FileNotFoundException: Unable to locate jenkins.xml file within executable directory or any parents
at winsw.ServiceDescriptor..ctor()
at winsw.WrapperService.Run(String[] _args, ServiceDescriptor descriptor)
at winsw.WrapperService.Main(String[] args)
Solution:
Save your jenkins-agent file as xml format. not just jenkins-agent.xml
we can use notepad++ to save the xml type.
similarly remove .exe at end of jenkins-agent.exe
Hope its useful.... cheers !!
The className, stopTimeout and stopParentFirst should not be in lower case.

Microsoft Word crashes when invoking its COM inside Docker Container

I am building a document conversion service which needs to:
Support Office documents as input.
Be pixel accurate (i.e. Openoffice and friends are not an acceptable alternative).
The service works well in the Windows host (it uses Office Interop from C#), but I would like to containerize it to simplify CI.
I am aware that Microsoft explicitly discourages using Office server-side but that's not a valid answer due to the reasons above.
Here is a minimal, simplified reproduction of the problem.
I am creating a Docker image with Microsoft Office using this Dockerfile:
FROM microsoft/windowsservercore:10.0.14393.953
# Install Office deployment tool
ADD https://download.microsoft.com/download/2/7/A/27AF1BE6-DD20-4CB4-B154-EBAB8A7D4A7E/officedeploymenttool_8008-3601.exe C:/deploymenttool_autoextract.exe
RUN C:/deploymenttool_autoextract.exe /quiet /passive /extract:C:
# Install Office
RUN C:/setup.exe /configure configuration.xml
ENTRYPOINT powershell
Building the image works just fine (it takes a while but everything seems to be installed properly):
PS C:\> docker build -t office2016 .
Sending build context to Docker daemon 9.513 MB
Step 1/5 : FROM microsoft/windowsservercore:10.0.14393.953
---> b4713e4d8bab
Step 2/5 : ADD https://download.microsoft.com/download/2/7/A/27AF1BE6-DD20-4CB4-B154-EBAB8A7D4A7E/officedeploymenttool_8008-3601.exe C:/deploymenttool_autoextract.exe
Downloading [==================================================>] 2.373 MB/2.373 MB
---> Using cache
---> 44646838dccb
Step 3/5 : RUN C:/deploymenttool_autoextract.exe /quiet /passive /extract:C:
---> Using cache
---> 34c29ed81a48
Step 4/5 : RUN C:/setup.exe /configure configuration.xml
---> Using cache
---> ffaff2d4c553
Step 5/5 : ENTRYPOINT powershell
---> Using cache
---> 3c0905d88e16
Successfully built 3c0905d88e16
PS C:\>
But, using Office (word specifically) fails:
PS C:\> docker run -ti office2016
Windows PowerShell
Copyright (C) 2016 Microsoft Corporation. All rights reserved.
PS C:\> $Word = New-Object -ComObject Word.Application
New-Object : Retrieving the COM class factory for component with CLSID {000209FF-0000-0000-C000-000000000046} failed due to the following error: 80080005
Server execution failed (Exception from HRESULT: 0x80080005 (CO_E_SERVER_EXEC_FAILURE)).
At line:1 char:9
+ $Word = New-Object -ComObject Word.Application
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ResourceUnavailable: (:) [New-Object], COMException
+ FullyQualifiedErrorId : NoCOMClassIdentified,Microsoft.PowerShell.Commands.NewObjectCommand
PS C:\>
I found this KERNELBASE.dll crash in the event logs:
PS C:\> Get-EventLog -LogName Application -After (Get-Date).AddMinutes(-1) | Format-Table -Wrap -AutoSize
Index Time EntryType Source InstanceID Message
----- ---- --------- ------ ---------- -------
264 Mar 29 06:35 Information Windows Error Reporting 1001 Fault bucket 108819405901, type 1
Event Name: APPCRASH
Response: Not available
Cab Id: 0
Problem signature:
P1: WINWORD.EXE
P2: 16.0.7870.2031
P3: 58d7f952
P4: KERNELBASE.dll
P5: 10.0.14393.953
P6: 58ba586d
P7: c06d007e
P8: 000da882
P9:
P10:
Attached files:
\\?\C:\Windows\Temp\WER1F8D.tmp.csv
\\?\C:\Windows\Temp\WER1F8E.tmp.txt
These files may be available here:
C:\ProgramData\Microsoft\Windows\WER\ReportArchive\AppCrash_WINWORD.EXE_31f9c9
d9099ee9f1dcb30a4d4769b8bed7fbe78_7d4a7f4a_08071f9d
Analysis symbol:
Rechecking for solution: 0
Report Id: 39ac8782-7405-4d3d-acf6-401aeeedcfe7
Report Status: 4104
Hashed bucket: d26bd2875cf81eb545bb270d4c18672b
263 Mar 29 06:35 Information Windows Error Reporting 1001 Fault bucket , type 0
Event Name: APPCRASH
Response: Not available
Cab Id: 0
Problem signature:
P1: WINWORD.EXE
P2: 16.0.7870.2031
P3: 58d7f952
P4: KERNELBASE.dll
P5: 10.0.14393.953
P6: 58ba586d
P7: c06d007e
P8: 000da882
P9:
P10:
Attached files:
These files may be available here:
C:\ProgramData\Microsoft\Windows\WER\ReportQueue\AppCrash_WINWORD.EXE_31f9c9d9
099ee9f1dcb30a4d4769b8bed7fbe78_7d4a7f4a_182f1a5d
Analysis symbol:
Rechecking for solution: 0
Report Id: 39ac8782-7405-4d3d-acf6-401aeeedcfe7
Report Status: 4100
Hashed bucket:
262 Mar 29 06:35 Error Application Error 1000 Faulting application name: WINWORD.EXE, version: 16.0.7870.2031, time stamp:
0x58d7f952
Faulting module name: KERNELBASE.dll, version: 10.0.14393.953, time stamp:
0x58ba586d
Exception code: 0xc06d007e
Fault offset: 0x000da882
Faulting process id: 0x1714
Faulting application start time: 0x01d2a8915664ac21
Faulting application path: C:\Program Files (x86)\Microsoft
Office\Root\Office16\WINWORD.EXE
Faulting module path: C:\Windows\System32\KERNELBASE.dll
Report Id: 39ac8782-7405-4d3d-acf6-401aeeedcfe7
Faulting package full name:
Faulting package-relative application ID:
261 Mar 29 06:35 0 Software Protection Platform Service 1073742727 The Software Protection service has stopped.
260 Mar 29 06:35 Information Software Protection Platform Service 1073758208 Successfully scheduled Software Protection service for re-start at
2017-03-30T13:15:26Z. Reason: RulesEngine.
PS C:\>
I welcome suggestions on how to fix this or any other way to convert Office documents in a pixel-accurate manner, preferably inside a Docker container.
Extra information
I am using Docker 1.13:
PS C:\build> docker version
Client:
Version: 1.13.0
API version: 1.25
Go version: go1.7.3
Git commit: 49bf474
Built: Wed Jan 18 16:20:26 2017
OS/Arch: windows/amd64
Server:
Version: 1.13.0
API version: 1.25 (minimum version 1.24)
Go version: go1.7.3
Git commit: 49bf474
Built: Wed Jan 18 16:20:26 2017
OS/Arch: windows/amd64
Experimental: false
Here is the Report.wer file from the crash:
Version=1
EventType=APPCRASH
EventTime=131352685691694832
ReportType=2
Consent=1
UploadTime=131352685700338868
ReportIdentifier=989281b5-1485-11e7-a710-eaddffe2c349
IntegratorReportIdentifier=269019fe-dcbd-435a-adc2-2420ed62b0ba
WOW64=1
NsAppName=WINWORD.EXE
AppSessionGuid=00001934-0018-000e-c921-465a92a8d201
TargetAppId=W:0000da39a3ee5e6b4b0d3255bfef95601890afd80709!0000da39a3ee5e6b4b0d3255bfef95601890afd80709!WINWORD.EXE
TargetAppVer=2017//03//26:17:24:34!1df35e!WINWORD.EXE
BootId=4294967295
Response.BucketId=d26bd2875cf81eb545bb270d4c18672b
Response.BucketTable=1
Response.LegacyBucketId=108819405901
Response.type=4
Response.CabId=107979656579
Sig[0].Name=Application Name
Sig[0].Value=WINWORD.EXE
Sig[1].Name=Application Version
Sig[1].Value=16.0.7870.2031
Sig[2].Name=Application Timestamp
Sig[2].Value=58d7f952
Sig[3].Name=Fault Module Name
Sig[3].Value=KERNELBASE.dll
Sig[4].Name=Fault Module Version
Sig[4].Value=10.0.14393.953
Sig[5].Name=Fault Module Timestamp
Sig[5].Value=58ba586d
Sig[6].Name=Exception Code
Sig[6].Value=c06d007e
Sig[7].Name=Exception Offset
Sig[7].Value=000da882
DynamicSig[1].Name=OS Version
DynamicSig[1].Value=10.0.14393.2.0.0.400.8
DynamicSig[2].Name=Locale ID
DynamicSig[2].Value=1033
DynamicSig[22].Name=Additional Information 1
DynamicSig[22].Value=2beb
DynamicSig[23].Name=Additional Information 2
DynamicSig[23].Value=2beba6fb4680d73a8c78ca7c24ccdb46
DynamicSig[24].Name=Additional Information 3
DynamicSig[24].Value=9cd2
DynamicSig[25].Name=Additional Information 4
DynamicSig[25].Value=9cd2e275ccb4247c4efe4926a99dfc92
UI[2]=C:\Program Files (x86)\Microsoft Office\Root\Office16\WINWORD.EXE
UI[5]=Check online for a solution (recommended)
UI[6]=Check for a solution later (recommended)
UI[7]=Close
UI[8]=Microsoft Word stopped working and was closed
UI[9]=A problem caused the application to stop working correctly. Windows will notify you if a solution is available.
UI[10]=&Close
LoadedModule[0]=C:\Program Files (x86)\Microsoft Office\Root\Office16\WINWORD.EXE
LoadedModule[1]=C:\Windows\SYSTEM32\ntdll.dll
LoadedModule[2]=C:\Windows\System32\KERNEL32.DLL
LoadedModule[3]=C:\Windows\System32\KERNELBASE.dll
LoadedModule[4]=C:\Windows\System32\ADVAPI32.dll
LoadedModule[5]=C:\Windows\System32\msvcrt.dll
LoadedModule[6]=C:\Windows\System32\sechost.dll
LoadedModule[7]=C:\Windows\System32\RPCRT4.dll
LoadedModule[8]=C:\Windows\System32\SspiCli.dll
LoadedModule[9]=C:\Windows\System32\CRYPTBASE.dll
LoadedModule[10]=C:\Windows\System32\bcryptPrimitives.dll
LoadedModule[11]=C:\Windows\System32\ucrtbase.dll
LoadedModule[12]=C:\Program Files (x86)\Microsoft Office\Root\Office16\AppVIsvSubsystems32.dll
LoadedModule[13]=C:\Windows\System32\USER32.dll
LoadedModule[14]=C:\Windows\System32\win32u.dll
LoadedModule[15]=C:\Windows\System32\GDI32.dll
LoadedModule[16]=C:\Windows\System32\gdi32full.dll
LoadedModule[17]=C:\Windows\System32\SHELL32.dll
LoadedModule[18]=C:\Windows\System32\cfgmgr32.dll
LoadedModule[19]=C:\Windows\System32\windows.storage.dll
LoadedModule[20]=C:\Windows\System32\combase.dll
LoadedModule[21]=C:\Windows\System32\powrprof.dll
LoadedModule[22]=C:\Windows\System32\shlwapi.dll
LoadedModule[23]=C:\Windows\System32\kernel.appcore.dll
LoadedModule[24]=C:\Windows\System32\shcore.dll
LoadedModule[25]=C:\Windows\System32\profapi.dll
LoadedModule[26]=C:\Windows\System32\ole32.dll
LoadedModule[27]=C:\Program Files (x86)\Microsoft Office\Root\Office16\VCRUNTIME140.dll
LoadedModule[28]=C:\Program Files (x86)\Microsoft Office\Root\Office16\AppVIsvStream32.dll
LoadedModule[29]=C:\Windows\SYSTEM32\USERENV.dll
LoadedModule[30]=C:\Program Files (x86)\Microsoft Office\Root\Office16\c2r32.dll
LoadedModule[31]=C:\Windows\System32\OLEAUT32.dll
LoadedModule[32]=C:\Windows\System32\msvcp_win.dll
LoadedModule[33]=C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\mso20win32client.dll
LoadedModule[34]=C:\Program Files (x86)\Microsoft Office\Root\Office16\MSVCP140.dll
LoadedModule[35]=C:\Program Files (x86)\Microsoft Office\Root\Office16\wwlib.dll
LoadedModule[36]=C:\Windows\SYSTEM32\d3d11.dll
LoadedModule[37]=C:\Windows\WinSxS\x86_microsoft.windows.gdiplus_6595b64144ccf1df_1.1.14393.953_none_baad48403594ab3f\gdiplus.dll
LoadedModule[38]=C:\Program Files (x86)\Microsoft Office\Root\Office16\oart.dll
LoadedModule[39]=C:\Windows\SYSTEM32\dxgi.dll
LoadedModule[40]=C:\Windows\WinSxS\x86_microsoft.windows.common-controls_6595b64144ccf1df_6.0.14393.953_none_89c2555adb023171\COMCTL32.dll
LoadedModule[41]=C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\mso30win32client.dll
LoadedModule[42]=C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\mso40uiwin32client.dll
LoadedModule[43]=C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\mso50win32client.dll
LoadedModule[44]=C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\mso98win32client.dll
LoadedModule[45]=C:\Windows\SYSTEM32\WTSAPI32.dll
LoadedModule[46]=C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\mso99Lwin32client.dll
LoadedModule[47]=C:\Windows\SYSTEM32\MSIMG32.dll
LoadedModule[48]=C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\mso.dll
LoadedModule[49]=C:\Windows\SYSTEM32\msi.dll
LoadedModule[50]=C:\Windows\SYSTEM32\bcrypt.dll
LoadedModule[51]=C:\Windows\SYSTEM32\d2d1.dll
LoadedModule[52]=C:\Windows\SYSTEM32\CRYPT32.dll
LoadedModule[53]=C:\Windows\SYSTEM32\MSASN1.dll
LoadedModule[54]=C:\Windows\SYSTEM32\WINSTA.dll
LoadedModule[55]=C:\Windows\SYSTEM32\VERSION.dll
LoadedModule[56]=C:\Program Files (x86)\Common Files\Microsoft Shared\Office16\MSPTLS.DLL
LoadedModule[57]=C:\Windows\SYSTEM32\d3d10warp.dll
State[0].Key=Transport.DoneStage1
State[0].Value=1
File[0].CabName=WERInternalMetadata.xml
File[0].Path=WERC595.tmp.WERInternalMetadata.xml
File[0].Flags=851970
File[0].Type=5
File[0].Original.Path=\\?\C:\ProgramData\Microsoft\Windows\WER\Temp\WERC595.tmp.WERInternalMetadata.xml
File[1].CabName=triagedump.dmp
File[1].Path=triagedump.dmp
File[1].Flags=808255490
File[1].Type=6
File[2].CabName=WERGenerationLog.txt
File[2].Flags=851970
File[2].Type=5
File[2].Buffer=FFFE53006E0061007000730068006F0074002000640075006D007000650072002000640065006100630074006900760061007400650064002E000D000A002D002000200053006E0061007000730068006F007400200061007600610069006C00610062006C0065003A00200030002E000D000A002D002000200053006E0061007000730068006F00740073002000640069007300610062006C00650064003A002000300030002E000D000A002D002000200020002000200053006E0061007000730068006F00740020007300740061007400750073003A002000430030003000300030003000360031002E000D000A002D002000200020002000200020002000440075006D0070006500720020007300740061007400750073003A002000300030003000300030003000300031002E000D000A002D00200020002000500072006F0063006500730073002000570045005200200066006C006100670073003A002000300030003000300030003000300030002E000D000A002D00200057006100740073006F006E00200072006500710075006500730074002000640075006D0070003A002000300030003100300030003100410034002E000D000A000D000A0053006E0061007000730068006F0074002000640075006D007000650072002000640065006100630074006900760061007400650064002E000D000A002D002000200053006E0061007000730068006F007400200061007600610069006C00610062006C0065003A00200030002E000D000A002D002000200053006E0061007000730068006F00740073002000640069007300610062006C00650064003A002000300030002E000D000A002D002000200020002000200053006E0061007000730068006F00740020007300740061007400750073003A002000430030003000300030003000360031002E000D000A002D002000200020002000200020002000440075006D0070006500720020007300740061007400750073003A002000300030003000300030003000300031002E000D000A002D00200020002000500072006F0063006500730073002000570045005200200066006C006100670073003A002000300030003000300030003000300030002E000D000A002D00200057006100740073006F006E00200072006500710075006500730074002000640075006D0070003A002000300030003100300030003100410034002E000D000A000D000A00
File[3].CabName=memory.csv
File[3].Path=WERCE00.tmp.csv
File[3].Flags=851971
File[3].Type=5
File[3].Original.Path=\\?\C:\Windows\Temp\WERCE00.tmp.csv
File[4].CabName=sysinfo.txt
File[4].Path=WERCE30.tmp.txt
File[4].Flags=851971
File[4].Type=5
File[4].Original.Path=\\?\C:\Windows\Temp\WERCE30.tmp.txt
File[5].CabName=Report.cab
File[5].Path=Report.cab
File[5].Flags=196608
File[5].Type=11
File[5].Original.Path=\\?\C:\Windows\system32\Report.cab
FriendlyEventName=Stopped working
ConsentKey=APPCRASH
AppName=Microsoft Word
AppPath=C:\Program Files (x86)\Microsoft Office\Root\Office16\WINWORD.EXE
NsPartner=windows
NsGroup=windows8
ApplicationIdentity=51EB66DF67BACB90D7BBEDF0AB950AC2
MetadataHash=497883896
I am using Windows Server 2016 as the Docker host:
PS C:\> [System.Environment]::OSVersion
Platform ServicePack Version VersionString
-------- ----------- ------- -------------
Win32NT 10.0.14393.0 Microsoft Windows NT 10.0.14393.0
Specifically, I am running this vagrant image: https://atlas.hashicorp.com/StefanScherer/boxes/windows_2016_docker
Finally, it seems that at least another person has tried to do this with Office 2013, also without success. See:
https://forums.docker.com/t/appcrash-kernelbase-dll-error-when-i-try-to-use-microsoft-office-in-docker-container/25706
https://answers.microsoft.com/en-us/msoffice/forum/msoffice_install-mso_winother/appcrash-kernelbasedll-error-when-i-try-to-use/c40e9fb8-fdbc-4245-b0fd-06c035e37c7b
https://forums.docker.com/t/appcrash-kernelbase-dll-error-when-i-try-to-use-microsoft-office-in-docker-container/25706/10 was updated with a working solution.

Is there a way to include 'Remote Controller name' in *.runsettings file?

I'm having a integrated environment with TFS BuildServer + TestControler + Several TestAgents.
Previously I used a *.testsettings file and define the remote server under Roles.
I update the BuildServer to VS2013 and introduced SpecRun for test executions.
As i'm having a custom *.srprofile file for TFS, I have to use a .runsettings file instead of .testsettings file.
I can not find a tag where i can define "Remote Controller name" in .runsettings file.
Is there a way to include 'Remote Controller name' in *.runsettings file??
I'm very new to Build Configurations. Any insight highly appreciated.
Additional Details:
I found this article and defined the .testsettings file path inside the .runsettings file. Following are the changed files according to the article.
But It's not working.
May be SpecRun Adaptor do not support tag.
TestSettings file i used.
<?xml version="1.0" encoding="UTF-8"?>
<TestSettings name=".........." id="........." xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2010">
<Description>Remote settings for running the tests on.....</Description>
<Deployment>
....
</Deployment>
<RemoteController name=".....local:6901" />
<Execution location="Remote">
<TestTypeSpecific>
<UnitTestRunConfig testTypeId=".....">
<AssemblyResolution>
<TestDirectory useLoadContext="true" />
</AssemblyResolution>
</UnitTestRunConfig>
</TestTypeSpecific>
<AgentRule name=".....">
</AgentRule>
</Execution>
<Properties />
</TestSettings>
Sample *.runsettings file i'm using now.
<?xml version="1.0" encoding="utf-8"?>
<RunSettings>
<!-- Configurations that affect the Test Framework -->
<RunConfiguration>
<!-- Path relative to solution directory -->
<ResultsDirectory>......</ResultsDirectory>
</RunConfiguration>
<SpecRun>
<Profile>TFS.srprofile</Profile>
<ReportFile>TestResults.html</ReportFile>
<GenerateSpecRunTrait>true</GenerateSpecRunTrait>
<GenerateFeatureTrait>false</GenerateFeatureTrait>
<SettingsFile>.....\Remote.AutoTest_2013.testsettings</SettingsFile>
<ForcedLegacyMode>true</ForcedLegacyMode>
</SpecRun>
</RunSettings>
OK, I think the mistake you've made is to use the runsettings file. You specify it in the testsettings file instead. Ours looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<TestSettings name="RemoteTest" id="9cfa5873-0238-4d56-a1ec-079192fa72c8" xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2010">
<Description>Settings set up to run remotely through test controller</Description>
<RemoteController name="**YOURCONTROLLERMACHINE**" />
<Execution location="Remote" hostProcessPlatform="MSIL">
<TestTypeSpecific>
<UnitTestRunConfig testTypeId="13cdc9d9-ddb5-4fa4-a97d-d965ccfc6d4b">
<AssemblyResolution>
<TestDirectory useLoadContext="true" />
</AssemblyResolution>
</UnitTestRunConfig>
</TestTypeSpecific>
<AgentRule name="AllAgentsDefaultRole">
</AgentRule>
</Execution>
<Properties />
</TestSettings>
You then call this from the command line, passing in the testsettings path:
"C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\CommonExtensions\Microsoft\TestWindow\vstest.console.exe" "C:\blahblah\TestsAssembly.dll" /Logger:trx /settings:C:\DummyTests\Remote.testsettings /Platform:x64
Where TestsAssembly.dll contains the tests you want to run, and Remote.testsettings is as above. The resultant .trx file appears in \TestResults...
You shouldn't need the runsettings file at all.

How to bind to an assembly outside the /bin folder

I have a web-site named CCESD set up in IIS7; my application root folder is D:\Websites\CCESD\CCESD. I also have a folder holding third-party assemblies (not all of which are strong-named) at D:\Websites\CCESD\CCESD\BinCommon: this is because I also have many other web applications under this root site in IIS that will share the DLLs, some of which are unmanaged code and so can't go in the GAC. My web.config file looks like this:
<compilation defaultLanguage="c#" debug="true" targetFramework="4.0">
<assemblies>
...
<add assembly="Telerik.Web.UI, Version=2012.1.288.40, Culture=neutral, PublicKeyToken=121FAE78165BA3D4" />
</assemblies>
</compilation>
...
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<probing privatePath="BinCommon" />
</assemblyBinding>
</runtime>
However, when I try to run the web application, I get the following error (after enabling assembly-binding error logging):
Parser Error Message: Could not load file or assembly 'Telerik.Web.UI,
Version=2012.1.288.40, Culture=neutral,
PublicKeyToken=121fae78165ba3d4' or one of its dependencies. The
system cannot find the file specified.
Source File: D:\Websites\CCESD\CCESD\web.config Line: 144
Assembly Load Trace: The following information can be helpful to
determine why the assembly 'Telerik.Web.UI, Version=2012.1.288.40,
Culture=neutral, PublicKeyToken=121fae78165ba3d4' could not be loaded.
Assembly manager loaded from:
C:\Windows\Microsoft.NET\Framework64\v4.0.30319\clr.dll
Running under executable c:\windows\system32\inetsrv\w3wp.exe
--- A detailed error log follows.
=== Pre-bind state information ===
LOG: User = IIS APPPOOL\CCESD
LOG: DisplayName = Telerik.Web.UI, Version=2012.1.288.40, Culture=neutral,PublicKeyToken=121fae78165ba3d4 (Fully-specified)
LOG: Appbase = file:///D:/Websites/CCESD/CCESD/
LOG: Initial PrivatePath = D:\Websites\CCESD\CCESD\bin Calling
assembly : (Unknown). ===
LOG: This bind starts in default load context.
LOG: Using application configuration file:
D:\Websites\CCESD\CCESD\web.configLOG: Using host configuration file:
C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet.config
LOG: Using machine configuration file from
C:\Windows\Microsoft.NET\Framework64\v4.0.30319\config\machine.config.
LOG: Post-policy reference: Telerik.Web.UI, Version=2012.1.288.40,
Culture=neutral, PublicKeyToken=121fae78165ba3d4
LOG: Attempting download of new URL
file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/Temporary
ASP.NET Files/root/e11e9098/9e133b72/Telerik.Web.UI.DLL.
LOG: Attempting download of new URL
file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/Temporary
ASP.NET
Files/root/e11e9098/9e133b72/Telerik.Web.UI/Telerik.Web.UI.DLL.
LOG: Attempting download of new URL
file:///D:/Websites/CCESD/CCESD/bin/Telerik.Web.UI.DLL.
LOG: Attempting download of new URL
file:///D:/Websites/CCESD/CCESD/bin/Telerik.Web.UI/Telerik.Web.UI.DLL.
LOG: Attempting download of new URL
file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/Temporary
ASP.NET Files/root/e11e9098/9e133b72/Telerik.Web.UI.EXE.
LOG: Attempting download of new URL
file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/Temporary
ASP.NET
Files/root/e11e9098/9e133b72/Telerik.Web.UI/Telerik.Web.UI.EXE.
LOG: Attempting download of new URL
file:///D:/Websites/CCESD/CCESD/bin/Telerik.Web.UI.EXE.
LOG: Attempting download of new URL
file:///D:/Websites/CCESD/CCESD/bin/Telerik.Web.UI/Telerik.Web.UI.EXE.
I have checked that the file exists and the version and public-key information are correct. What am I doing wrong?
I found it eventually; in the end, it was down to this:
<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
My project began life in Visual Studio 2005; hence the xmlns attribute shown above was present in the containing element of my web.config file. Removing it fixed the problem and now my assemblies are being loaded correctly.
Googling reveals that the xmlns attribute is there to enable intellisense in Visual Studio (which indeed it does): it says nothing about having any effect on loading assemblies, so this is all a little strange (not to mention annoying). Still, now it's working.

Jaxb binding file being ignored

I having a bit of trouble building JAXB bindings fora set of schemas and its driving me a bit batty. Here is the schema in question (it is just one of may schema in this particular build):
<schema xmlns="http://www.w3.org/2001/XMLSchema" xmlns:xml="http://www.w3.org/XML/1998/namespace" targetNamespace="http://www.w3.org/XML/1998/namespace">
<attribute name="lang" type="language">
<annotation>
<documentation>In due course, we should install the relevant ISO 2- and 3-letter
codes as the enumerated possible values . . .</documentation>
</annotation>
</attribute>
<attribute name="space" default="preserve">
<simpleType>
<restriction base="NCName">
<enumeration value="default"/>
<enumeration value="preserve"/>
</restriction>
</simpleType>
</attribute>
<attributeGroup name="specialAttrs">
<attribute ref="xml:lang"/>
<attribute ref="xml:space"/>
</attributeGroup>
xjc is claiming that the attributes declared above are already declared elsewhere:
parsing a schema...
[ERROR] 'lang' is already defined
line 26 of file:../../gml/3.1.1/smil/xml-mod.xsd
[ERROR] (related to above error) the first definition appears here
line 88 of http://www.w3.org/2001/03/xml.xsd
[ERROR] 'space' is already defined
line 34 of file:../../gml/3.1.1/smil/xml-mod.xsd
[ERROR] (related to above error) the first definition appears here
line 95 of http://www.w3.org/2001/03/xml.xsd
[ERROR] 'specialAttrs' is already defined
line 39 of file:../../gml/3.1.1/smil/xml-mod.xsd
[ERROR] (related to above error) the first definition appears here
line 111 of http://www.w3.org/2001/03/xml.xsd
Failed to parse a schema.
Doing a bit of research would lead me to believe that the problem is that I need a binding file to resolve the duplicate attributes....and I have one :
<jaxb:bindings version="1.0" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xjc="http://java.sun.com/xml/ns/jaxb/xjc" jaxb:extensionBindingPrefixes="xjc">
<jaxb:bindings schemaLocation="../../gml/3.1.1/smil/xml-mod.xsd" node="/xs:schema">
<jaxb:bindings node="//xs:attribute[#name='lang']">
<jaxb:property name="langAttribute"/>
</jaxb:bindings>
<jaxb:bindings node="//xs:attribute[#name='space']">
<jaxb:property name="spaceAttribute"/>
</jaxb:bindings>
<jaxb:bindings node="//xs:attributeGroup[#name='specialAttrs']">
<jaxb:property name="specialAttrsAttribute"/>
</jaxb:bindings>
</jaxb:bindings>
Yet the problem persists. The error message with or without the bindings file is the same. I know the file is being used , because if I mess up the xpath for the node selector I get an error message. It's like xjc knows the bindings file is there but ignores it.
Here's the command line that fails to build the bindings:
C:\tools\jaxb-ri-20110512\bin\xjc -episode ..\..\..\common.ogc -d ..\..\..\src -p com.ogc.bindings -b ..\..\..\bindings.xsd -catalog ..\..\..\ogc.cat -extension sosAll.xsd
I have tried this with both the jdk6 native jaxb (2.0) and jaxb 2.2.4 (I installed the jaxb-api.jar in the endorsed directory)
XJC (bundled with JDK), ignores binding file, if the path to the binding file or the XSD / WSDL is too long.
Issue observed and confirmed on Oracle 64 bit JDK 1.6.0.45, on Windows 7 ultimate and on Linux, XJC (bundled with JDK), ignores binding file, if the path to the binding file is too long.
I did NOT have the time to do detail research on the issue; I solved my problem by simply shortening the svn checkout path. It was the most bizarre issue - I could not reproduce the problem on my Windows 8 Laptop and on Linux, but on a Windows 7 workstation, build kept on failing. I identified this issue by confirming that other then path, there is NO difference between Windows 8 LAPTOP, where the build works, vs. Windows 7 Ultimate where the path is a bit long (6 characters -> /trunk).
Problem was solved without any code, configuration, xml schema or binding file change. Posting here so that others who may run into this, have a bit of easier time then me.
i believe this is an issue with namespace collision, you dont have a namespace defined for your schema elements and it seems you are using names for your attributes that are in conflict with the ones defined in xml's schema (xml.xsd)

Resources