MSB4017 InternalLoggerException System.ArgumentNullException: Parameter "projectProperty" cannot be null.
- Dominant language
- C#
- Stars
- 5.5k
- Forks
- 1.5k
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 141
Description
Porting https://github.com/dotnet/runtime/issues/34820
```
2020-04-10T13:54:36.4464394Z Time Elapsed 00:02:01.94
2020-04-10T13:54:36.4702588Z MSBUILD : error MSB4017: The build stopped unexpectedly because of an unexpected logger failure.
2020-04-10T13:54:36.4708316Z Microsoft.Build.Exceptions.InternalLoggerException: The build stopped unexpectedly because of an unexpected logger failure.
2020-04-10T13:54:36.4709785Z ---> System.ArgumentNullException: Parameter "projectProperty" cannot be null.
2020-04-10T13:54:36.4710517Z at Microsoft.Build.Shared.ErrorUtilities.VerifyThrowArgumentNull(Object parameter, String parameterName, String resourceName)
2020-04-10T13:54:36.4711180Z at Microsoft.Build.Collections.CopyOnWritePropertyDictionary`1.Set(T projectProperty)
2020-04-10T13:54:36.4711735Z at Microsoft.Build.Execution.ProjectItemInstance.TaskItem.get_MetadataCollection()
2020-04-10T13:54:36.4712263Z at Microsoft.Build.Execution.ProjectItemInstance.TaskItem.CloneCustomMetadata()
2020-04-10T13:54:36.4712784Z at Microsoft.Build.Logging.BuildEventArgsWriter.Write(ITaskItem item)
2020-04-10T13:54:36.4713290Z at Microsoft.Build.Logging.BuildEventArgsWriter.WriteItems(IEnumerable items)
2020-04-10T13:54:36.4713915Z at Microsoft.Build.Logging.BinaryLogger.Write(BuildEventArgs e)
2020-04-10T13:54:36.4714445Z at Microsoft.Build.BackEnd.Logging.EventSourceSink.RaiseAnyEvent(Object sender, BuildEventArgs buildEvent)
2020-04-10T13:54:36.4715224Z --- End of inner exception stack trace ---
2020-04-10T13:54:36.4716248Z at Microsoft.Build.Exceptions.InternalLoggerException.Throw(Exception innerException, BuildEventArgs e, String messageResourceName, Boolean initializationException, String[] messageArgs)
2020-04-10T13:54:36.4717058Z at Microsoft.Build.BackEnd.Logging.EventSourceSink.RaiseAnyEvent(Object sender, BuildEventArgs buildEvent)
2020-04-10T13:54:36.4717714Z at Microsoft.Build.BackEnd.Logging.EventSourceSink.RaiseAnyEvent(Object sender, BuildEventArgs buildEvent)
2020-04-10T13:54:36.5134290Z ##[error](NETCORE_ENGINEERING_TELEMETRY=Build) Build failed (exit code '1').
```
this occurred with `/__w/1/s/.dotnet/sdk/5.0.100-preview.4.20202.8/MSBuild.dll` on Android.
This would presumably include the change made to temporarily patch https://github.com/microsoft/msbuild/issues/4322
It seems there is some concurrent read/write going on in the dictionary here. It's obviously a copy-on-write dictionary -- should the "write" have been forced, before the logging thread gets hold of it @rainersigwald ?
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.