I have a Dynamics365 DevVM and updated it from 10PU26 to 10PU28 so that i develop on the same platform version as the systems i am developing for. After applying 10pu28 i started my VisualStudio, changed something and tried to save and compile but noticed that BP is broken and so i can't develop further. Visual Studio logs the following but i am not sure what i can do to fix this.
Build started 07/25/2019 06:27.
Build step: Metadata validation started.
Exception occured while performing operation Validate Metadata. Exception details: Path: []:System.ArgumentNullException: Value cannot be null.
Parameter name: source
at System.Linq.Enumerable.Contains[TSource](IEnumerable`1 source, TSource value, IEqualityComparer`1 comparer)
at Microsoft.Dynamics.Framework.Tools.ILGeneratorAgent.CompilationService.ValidateMetadata(String module, String metadataPath, String compilerMetadataPath, IEnumerable`1 referencedAssembliesFolders, IEnumerable`1 elements)
Build step: Metadata validation completed (10 ms).
Build step: X++ compilation, label generation and resource deployment started.
Build step: X++ compilation, label generation and resource deployment completed (670 ms).
Build step: Best practice check started.
Exception occured while performing operation Best practice checks. Exception details: BP Rule: [Exception occured while performing operation Best practice checks. Exception details]:System.ArgumentNullException: Value cannot be null.
Parameter name: referencedAssembliesFolders
at Microsoft.Dynamics.Framework.Tools.ILGeneratorAgent.MetadataProviderExtensions.AddReferenceProvider(IMetadataProvider provider, IEnumerable`1 referencedAssembliesFolders, IDiagnosticSink diagnostics, String modelModule, MetadataProviderFactory factory)
at Microsoft.Dynamics.Framework.Tools.ILGeneratorAgent.CompilationService.RunBestPracticeChecks(String module, String metadataPath, String compilerMetadataPath, IEnumerable`1 referencedAssembliesFolders, IEnumerable`1 elements, String modelName, Boolean isNormalizedCollectionNeeded)
Build step: Best practice check completed (9 ms).
Build completed (716 ms).
I attempted to disable running BP when building as a temporary workaround but that didn't work either. When BP is disabled i still can't compile. Here are the logs:
Build started 07/25/2019 06:40.
Build step: Metadata validation started.
Exception occured while performing operation Validate Metadata. Exception details: Path: []:System.ArgumentNullException: Value cannot be null.
Parameter name: source
at System.Linq.Enumerable.Contains[TSource](IEnumerable`1 source, TSource value, IEqualityComparer`1 comparer)
at Microsoft.Dynamics.Framework.Tools.ILGeneratorAgent.CompilationService.ValidateMetadata(String module, String metadataPath, String compilerMetadataPath, IEnumerable`1 referencedAssembliesFolders, IEnumerable`1 elements)
Build step: Metadata validation completed (8 ms).
Build step: X++ compilation, label generation and resource deployment started.
Build step: X++ compilation, label generation and resource deployment completed (381 ms).
Build completed (409 ms).