Skip to content

HttpStress.csproj fails to build again #51117

Closed

Description

@antonfirsov

According to the log a change between #50265 and #50244 broke the HttpStress builds:
https://dev.azure.com/dnceng/public/_build/results?buildId=1078046&view=logs&j=2d2b3007-3c5c-5840-9bb0-2b1ea49925f3&t=8ca65746-3bfa-57bf-9141-d805b5d39db5

Call stack:

C:\Program Files\dotnet\sdk\5.0.202\Sdks\Microsoft.NET.Sdk\targets\Microsoft.PackageDependencyResolution.targets(241,5): error MSB4018: The "ResolvePackageAssets" task failed unexpectedly.
System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values.
   at System.IO.Strategies.SyncWindowsFileStreamStrategy.Write(Byte[] buffer, Int32 offset, Int32 count) in /_/src/libraries/System.Private.CoreLib/src/System/IO/Strategies/SyncWindowsFileStreamStrategy.cs:line 64
   at System.IO.Strategies.BufferedFileStreamStrategy.Flush(Boolean flushToDisk) in /_/src/libraries/System.Private.CoreLib/src/System/IO/Strategies/BufferedFileStreamStrategy.cs:line 778
   at System.IO.Strategies.BufferedFileStreamStrategy.Dispose(Boolean disposing) in /_/src/libraries/System.Private.CoreLib/src/System/IO/Strategies/BufferedFileStreamStrategy.cs:line 167
   at System.IO.Stream.Close() in /_/src/libraries/System.Private.CoreLib/src/System/IO/Stream.cs:line 165
   at System.IO.BinaryWriter.Dispose(Boolean disposing) in /_/src/libraries/System.Private.CoreLib/src/System/IO/BinaryWriter.cs:line 75
   at System.IO.BinaryWriter.Dispose() in /_/src/libraries/System.Private.CoreLib/src/System/IO/BinaryWriter.cs:line 81
   at Microsoft.NET.Build.Tasks.ResolvePackageAssets.CacheWriter.WriteToCacheFile()
   at Microsoft.NET.Build.Tasks.ResolvePackageAssets.CacheReader.CreateReaderFromDisk(ResolvePackageAssets task, Byte[] settingsHash)
   at Microsoft.NET.Build.Tasks.ResolvePackageAssets.CacheReader..ctor(ResolvePackageAssets task)
   at Microsoft.NET.Build.Tasks.ResolvePackageAssets.ReadItemGroups()
   at Microsoft.NET.Build.Tasks.ResolvePackageAssets.ExecuteCore()
   at Microsoft.NET.Build.Tasks.TaskBase.Execute()
   at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
   at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask) [C:\app\HttpStress.csproj]

@ViktorHofer any hints?

Activity

  1. ghost added
    untriagedNew issue has not been triaged by the area owner
    on Apr 12, 2021
  2. removed
    untriagedNew issue has not been triaged by the area owner
    on Apr 12, 2021
  3. added this to the 6.0.0 milestone on Apr 12, 2021
  4. ViktorHofer commented on Apr 12, 2021

    @ViktorHofer
    Member

    Taking a look now

  5. ViktorHofer commented on Apr 12, 2021

    @ViktorHofer
    Member

    Without a binlog (which isn't produced nor uploaded) this is really hard to diagnose.

  6. antonfirsov commented on Apr 12, 2021

    @antonfirsov
    ContributorAuthor

    I have a local repro. How can I get the binlog(s) that can help diagnosing this?

    Here is the PR history between the last successful and the first failing CI run, in case any of them is obviously suspicious:

  7. ViktorHofer commented on Apr 12, 2021

    @ViktorHofer
    Member

    Add /bl to the build command and send me the binlog (name by default is msbuild.binlog) via Teams please (a binlog contains env vars).

  8. antonfirsov commented on Apr 14, 2021

    @antonfirsov
    ContributorAuthor

    I managed to track this to #50166 with git bisect. Setting DOTNET_SYSTEM_IO_USENET5COMPATFILESTREAM=1 fixes the issue.

    #50166 might be concerning regarding the ability of using .NET 6 with dotnet build from within a Windows docker container.

    /cc @adamsitnik

  9. antonfirsov commented on Apr 14, 2021

    @antonfirsov
    ContributorAuthor

    I see it has been addressed in #51151, trying again with fresh main.

  10. antonfirsov commented on Apr 14, 2021

    @antonfirsov
    ContributorAuthor

    #51151 fixed this, looks like an exceptional case (a library bug broke the SDK). @ViktorHofer thanks for your support!

  11. adamsitnik commented on Apr 14, 2021

    @adamsitnik
    Member

    #51151 fixed this

    @antonfirsov thank you for the confirmation!

  12. ghost locked as resolved and limited conversation to collaborators on May 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions