When I create a new Symfony 5.2 project and take its composer.json, VS2015 opens a project correctly the first time, i.e. it installs all the missing var, vendor etc files. When I then re-open the same project, VS2015 displays the info below in its composer output. This does not happen with a Symfony 5.1 composer.json.
System.AggregateException: One or more errors occurred. ---> System.NullReferenceException: Object reference not set to an instance of an object.
at PHP.Project.PHPProjectNode.GetModule(String packageName)
at PHP.Project.PHPProjectNode.IsModuleInstalled(String packageName)
at PHP.VisualStudio.Language.Nodes.Project.BuiltinPhpReferencesProvider.
.
()
at PHP.VisualStudio.Language.Nodes.Project.BuiltinPhpReferencesProvider.
.
.MoveNext()
at System.Linq.Enumerable.WhereEnumerableIterator`1.MoveNext()
at System.Collections.Generic.List`1.InsertRange(Int32 index, IEnumerable`1 collection)
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.QueryReferences()
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.EnsureReferences()
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.get_References()
at PHP.VisualStudio.Language.Nodes.Project.ProjectTablesWithReferences.GetClass(QualifiedName qname)
at Devsense.VisualStudio.Smarty.Framework.SmartyFrameworkProvider.SmartyFrameworks.IsSmartyPresent()
at Devsense.VisualStudio.Smarty.Framework.SmartyFrameworkProvider.SmartyFrameworks.get_Frameworks()
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.<>c.<UpdateFrameworks>b__32_0(IProjectFrameworks provider)
at System.Linq.Enumerable.<SelectManyIterator>d__17`2.MoveNext()
at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.UpdateFrameworks()
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.get_Frameworks()
at Devsense.PHP.Nodes.Environments.Config.Utils.GetRequiredExtensions(IProjectFolder project)
at Devsense.PHP.Nodes.Environments.CLI.CliEnvironment.Validate()
at Devsense.PHP.Nodes.Environments.CLI.PhpDevEnvironment.Validate()
at Devsense.PHP.Nodes.Environments.IssuesDialog.ValidateAndFixWithUI(IPhpEnvironment env, IssueFlags requiredFlags)
at PHP.Project.PHPProjectNode.GetPhpInterpreterPathInternal(Boolean verify)
at PHP.Project.Composer.ComposerManager.GetConfiguration()
at PHP.Project.Composer.ComposerManager.<GetConfigurationAsync>b__79_0()
at Microsoft.VisualStudioTools.UIThread.InvokeAsyncHelper[T](Func`1 func, TaskCompletionSource`1 tcs)
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at PHP.Project.Composer.ComposerManager.<GetConfigurationAsync>d__79.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.ComposerCommand.<ExecuteAsync>d__23.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.PathInitializer.<GetPackagePathsAsync>d__9.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.PathInitializer.<CreateIfNeededAsync>d__7.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.DMI.ProjectRootPackage.<CreateAsync>d__1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.ProjectRootPackageFactory.<CreateAsync>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.ComposerController.<RefreshAsync>d__38.MoveNext()
--- End of inner exception stack trace ---
---> (Inner Exception #0) System.NullReferenceException: Object reference not set to an instance of an object.
at PHP.Project.PHPProjectNode.GetModule(String packageName)
at PHP.Project.PHPProjectNode.IsModuleInstalled(String packageName)
at PHP.VisualStudio.Language.Nodes.Project.BuiltinPhpReferencesProvider.
.
()
at PHP.VisualStudio.Language.Nodes.Project.BuiltinPhpReferencesProvider.
.
.MoveNext()
at System.Linq.Enumerable.WhereEnumerableIterator`1.MoveNext()
at System.Collections.Generic.List`1.InsertRange(Int32 index, IEnumerable`1 collection)
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.QueryReferences()
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.EnsureReferences()
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.get_References()
at PHP.VisualStudio.Language.Nodes.Project.ProjectTablesWithReferences.GetClass(QualifiedName qname)
at Devsense.VisualStudio.Smarty.Framework.SmartyFrameworkProvider.SmartyFrameworks.IsSmartyPresent()
at Devsense.VisualStudio.Smarty.Framework.SmartyFrameworkProvider.SmartyFrameworks.get_Frameworks()
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.<>c.<UpdateFrameworks>b__32_0(IProjectFrameworks provider)
at System.Linq.Enumerable.<SelectManyIterator>d__17`2.MoveNext()
at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.UpdateFrameworks()
at PHP.VisualStudio.Language.Nodes.Project.ProjectContainer.get_Frameworks()
at Devsense.PHP.Nodes.Environments.Config.Utils.GetRequiredExtensions(IProjectFolder project)
at Devsense.PHP.Nodes.Environments.CLI.CliEnvironment.Validate()
at Devsense.PHP.Nodes.Environments.CLI.PhpDevEnvironment.Validate()
at Devsense.PHP.Nodes.Environments.IssuesDialog.ValidateAndFixWithUI(IPhpEnvironment env, IssueFlags requiredFlags)
at PHP.Project.PHPProjectNode.GetPhpInterpreterPathInternal(Boolean verify)
at PHP.Project.Composer.ComposerManager.GetConfiguration()
at PHP.Project.Composer.ComposerManager.<GetConfigurationAsync>b__79_0()
at Microsoft.VisualStudioTools.UIThread.InvokeAsyncHelper[T](Func`1 func, TaskCompletionSource`1 tcs)
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at PHP.Project.Composer.ComposerManager.<GetConfigurationAsync>d__79.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.ComposerCommand.<ExecuteAsync>d__23.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.PathInitializer.<GetPackagePathsAsync>d__9.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.PathInitializer.<CreateIfNeededAsync>d__7.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.DMI.ProjectRootPackage.<CreateAsync>d__1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.ProjectRootPackageFactory.<CreateAsync>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Devsense.PHP.Composer.ComposerController.<RefreshAsync>d__38.MoveNext()<---