Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test /bl for Azure Pipelines build #1748

Open
wants to merge 6 commits into
base: master
from

Conversation

@christophwille
Copy link
Member

christophwille commented Oct 9, 2019

@christophwille

This comment has been minimized.

Copy link
Member Author

christophwille commented Oct 9, 2019

Attached is the build log (zipped binlog) for the failed Release CI (original build at https://icsharpcode.visualstudio.com/icsharpcode-pipelines/_build/results?buildId=365)

msbuild_CI_Release.zip

To be honest it doesn't tell me more than the textual logs - @onovotny is this something we can debug on our end, or do we have to go to MS? (this build error is yet again different from what we usually see on master, and we don't see any on 5.0.x branch...)

@onovotny

This comment has been minimized.

Copy link
Contributor

onovotny commented Oct 9, 2019

This is weird. I'd suggest @nguerrera or @dsplaisted might be able to help?

@dsplaisted

This comment has been minimized.

Copy link

dsplaisted commented Oct 9, 2019

@rainersigwald Any ideas on what's going on here?

ALINK error AL1019: Metadata failure while creating assembly -- The process cannot access the file because it is being used by another process. [d:\a\1\s\ILSpy\ILSpy.csproj]

This might be relevant:

    <EmbeddedResource Include="Properties\Resources.resx">
      <Generator>PublicResXFileCodeGenerator</Generator>
      <LastGenOutput>Resources.Designer.cs</LastGenOutput>
    </EmbeddedResource>
    <EmbeddedResource Include="Properties\Resources.zh-Hans.resx" />
@onovotny

This comment has been minimized.

Copy link
Contributor

onovotny commented Oct 9, 2019

@dsplaisted what's weird is that it works in three of the four configurations?

@rainersigwald

This comment has been minimized.

Copy link

rainersigwald commented Nov 11, 2019

From the log, ILSpy.csproj is being built twice in parallel:

  1. ILSpy.WithPackage.sln -> ILSpy.csproj (default targets)
  2. ILSpy.WithPackage.sln -> ILSpy.Package.wapproj -> ILSpy.csproj (Build target, additional properties _WapBuildingInsideVisualStudio = ; GenerateAppxPackageOnBuild = false; BuildingInsideVisualStudio = false)

When both of those try to read/write the same file, one fails, producing this error.

I'm not sure whether this is a bug in ILSpy's build or in Microsoft.DesktopBridge.targets, but I strongly suspect the latter.

You can work around this by building single-threaded (not using msbuild -m/the maximumCpuCount argument to the MSBuild AzDO task), by not building the ILSpy.WithPackage solution, or by building ILSpy.Package.wapproj instead of the solution. It looks like your current AppVeyor configuration might do both of the first two. I would recommend the latter, but I'm not sure how that would affect running tests in this repo.

@christophwille

This comment has been minimized.

Copy link
Member Author

christophwille commented Nov 11, 2019

Another interesting tidbit is that the 5.0x branch never had build failures (see checkmarks on commits https://github.com/icsharpcode/ILSpy/commits/5.0.x except for real build breaks), the only difference is that 5.0x builds for net462 while master is net472.

@christophwille

This comment has been minimized.

Copy link
Member Author

christophwille commented Nov 11, 2019

@rainersigwald removing maximumCpuCount seems to have done the trick (was the least invasive change to the build process). Still, strange why one branch is fine, while the other fails regularly.

christophwille added a commit that referenced this pull request Nov 11, 2019
@dgrunwald

This comment has been minimized.

Copy link
Member

dgrunwald commented Nov 11, 2019

In addition to the net462 -> net472 change, master also upgraded MSBuild.Sdk.Extras from 2.0.24 to 2.0.54 and has the 5388a18 change.

@christophwille

This comment has been minimized.

Copy link
Member Author

christophwille commented Nov 12, 2019

I have applied the maximumCpuCount fix to master (got complaints already that the green checkmarks on commits aren't there although we build successfully on AppVeyor).

Still, I want to get to the bottom of this - why did it start failing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants
You can’t perform that action at this time.