ChocolateyGUI icon indicating copy to clipboard operation
ChocolateyGUI copied to clipboard

Failed to start application.

Open ObnubiladO opened this issue 1 year ago • 4 comments

Checklist

  • [X] I have verified this is the correct repository for opening this issue.
  • [X] I have verified no other issues exist related to my problem.
  • [X] I have verified this is not an issue for a specific package.
  • [X] I have verified this issue is not security related.
  • [X] I confirm I am using official, and not unofficial, or modified, Chocolatey products.

What You Are Seeing?

https://i.imgur.com/4KcwHAG.png

What is Expected?

Application launch.

How Did You Get This To Happen?

Not sure what happened. It was working fine in W10 and now in W11 it isn't working anymore.

System Details

  • Operating System: 10.0.22631.0
  • Windows PowerShell version: 5.1
  • Chocolatey CLI Version: 2.2.2
  • Chocolatey Licensed Extension version: Chocolatey v2.2.2
  • Chocolatey License type: Free
  • Terminal/Emulator: Windows PowerShell

Installed Packages

No, thanks.

Output Log

2024-01-04 21:15:35.873 +01:00 [Fatal] Failed to start application.
Autofac.Core.DependencyResolutionException: An error occurred during the activation of a particular registration. See the inner exception for details. Registration: Activator = ShellView[] (DelegateActivator), Services = [System.Collections.Generic.IEnumerable`1[[ChocolateyGui.Common.Windows.Views.ShellView, ChocolateyGui.Common.Windows, Version=2.1.0.0, Culture=neutral, PublicKeyToken=]]], Lifetime = Autofac.Core.Lifetime.CurrentScopeLifetime, Sharing = None, Ownership = ExternallyOwned ---> An error occurred during the activation of a particular registration. See the inner exception for details. Registration: Activator = ShellView (ReflectionActivator), Services = [ChocolateyGui.Common.Windows.Views.ShellView], Lifetime = Autofac.Core.Lifetime.CurrentScopeLifetime, Sharing = None, Ownership = OwnedByLifetimeScope ---> An error occurred during the activation of a particular registration. See the inner exception for details. Registration: Activator = ChocolateyConfigurationProvider (ReflectionActivator), Services = [ChocolateyGui.Common.Providers.IChocolateyConfigurationProvider], Lifetime = Autofac.Core.Lifetime.RootScopeLifetime, Sharing = Shared, Ownership = OwnedByLifetimeScope ---> An exception was thrown while invoking the constructor 'Void .ctor(chocolatey.infrastructure.filesystem.IFileSystem)' on type 'ChocolateyConfigurationProvider'. ---> Sequence contains more than one matching element (See inner exception for details.) (See inner exception for details.) (See inner exception for details.) (See inner exception for details.) ---> Autofac.Core.DependencyResolutionException: An error occurred during the activation of a particular registration. See the inner exception for details. Registration: Activator = ShellView (ReflectionActivator), Services = [ChocolateyGui.Common.Windows.Views.ShellView], Lifetime = Autofac.Core.Lifetime.CurrentScopeLifetime, Sharing = None, Ownership = OwnedByLifetimeScope ---> An error occurred during the activation of a particular registration. See the inner exception for details. Registration: Activator = ChocolateyConfigurationProvider (ReflectionActivator), Services = [ChocolateyGui.Common.Providers.IChocolateyConfigurationProvider], Lifetime = Autofac.Core.Lifetime.RootScopeLifetime, Sharing = Shared, Ownership = OwnedByLifetimeScope ---> An exception was thrown while invoking the constructor 'Void .ctor(chocolatey.infrastructure.filesystem.IFileSystem)' on type 'ChocolateyConfigurationProvider'. ---> Sequence contains more than one matching element (See inner exception for details.) (See inner exception for details.) (See inner exception for details.) ---> Autofac.Core.DependencyResolutionException: An error occurred during the activation of a particular registration. See the inner exception for details. Registration: Activator = ChocolateyConfigurationProvider (ReflectionActivator), Services = [ChocolateyGui.Common.Providers.IChocolateyConfigurationProvider], Lifetime = Autofac.Core.Lifetime.RootScopeLifetime, Sharing = Shared, Ownership = OwnedByLifetimeScope ---> An exception was thrown while invoking the constructor 'Void .ctor(chocolatey.infrastructure.filesystem.IFileSystem)' on type 'ChocolateyConfigurationProvider'. ---> Sequence contains more than one matching element (See inner exception for details.) (See inner exception for details.) ---> Autofac.Core.DependencyResolutionException: An exception was thrown while invoking the constructor 'Void .ctor(chocolatey.infrastructure.filesystem.IFileSystem)' on type 'ChocolateyConfigurationProvider'. ---> Sequence contains more than one matching element (See inner exception for details.) ---> System.InvalidOperationException: Sequence contains more than one matching element
   at System.Linq.Enumerable.SingleOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
   at ChocolateyGui.Common.Providers.ChocolateyConfigurationProvider.GetChocolateyInstallLocation() in C:\buildAgent\work\774e9aed9020e028\Source\ChocolateyGui.Common\Providers\ChocolateyConfigurationProvider.cs:line 41
   at lambda_method(Closure , Object[] )
   at Autofac.Core.Activators.Reflection.ConstructorParameterBinding.Instantiate()
   --- End of inner exception stack trace ---
   at Autofac.Core.Activators.Reflection.ConstructorParameterBinding.Instantiate()
   at Autofac.Core.Activators.Reflection.ReflectionActivator.ActivateInstance(IComponentContext context, IEnumerable`1 parameters)
   at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters)
   --- End of inner exception stack trace ---
   at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters)
   at Autofac.Core.Lifetime.LifetimeScope.GetOrCreateAndShare(Guid id, Func`1 creator)
   at Autofac.Core.Resolving.InstanceLookup.Execute()
   at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, IComponentRegistration registration, IEnumerable`1 parameters)
   at Autofac.Core.Activators.Reflection.ConstructorParameterBinding.Instantiate()
   at Autofac.Core.Activators.Reflection.ReflectionActivator.ActivateInstance(IComponentContext context, IEnumerable`1 parameters)
   at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters)
   --- End of inner exception stack trace ---
   at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters)
   at Autofac.Core.Resolving.InstanceLookup.Execute()
   at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, IComponentRegistration registration, IEnumerable`1 parameters)
   at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext()
   at System.Linq.Buffer`1..ctor(IEnumerable`1 source)
   at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
   at Autofac.Features.Collections.CollectionRegistrationSource.<>c__DisplayClass0_0.<RegistrationsFor>b__0(IComponentContext c, IEnumerable`1 p)
   at Autofac.Core.Activators.Delegate.DelegateActivator.ActivateInstance(IComponentContext context, IEnumerable`1 parameters)
   at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters)
   --- End of inner exception stack trace ---
   at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters)
   at Autofac.Core.Resolving.InstanceLookup.Execute()
   at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, IComponentRegistration registration, IEnumerable`1 parameters)
   at Autofac.Core.Resolving.ResolveOperation.Execute(IComponentRegistration registration, IEnumerable`1 parameters)
   at Autofac.ResolutionExtensions.TryResolveService(IComponentContext context, Service service, IEnumerable`1 parameters, Object& instance)
   at Autofac.ResolutionExtensions.ResolveService(IComponentContext context, Service service, IEnumerable`1 parameters)
   at ChocolateyGui.Common.Windows.Bootstrapper.GetAllInstances(Type service) in C:\buildAgent\work\774e9aed9020e028\Source\ChocolateyGui.Common.Windows\Bootstrapper.cs:line 179
   at Caliburn.Micro.ViewLocator.<>c.<.cctor>b__10_0(Type viewType)
   at Caliburn.Micro.ViewLocator.<>c.<.cctor>b__10_8(Object model, DependencyObject displayLocation, Object context)
   at Caliburn.Micro.WindowManager.CreateWindow(Object rootModel, Boolean isDialog, Object context, IDictionary`2 settings)
   at Caliburn.Micro.WindowManager.ShowWindow(Object rootModel, Object context, IDictionary`2 settings)
   at ChocolateyGui.Common.Windows.Bootstrapper.<OnStartup>d__43.MoveNext() in C:\buildAgent\work\774e9aed9020e028\Source\ChocolateyGui.Common.Windows\Bootstrapper.cs:line 138

Additional Context

I tried reinstalling chocolateygui, but it didn't work.

ObnubiladO avatar Jan 04 '24 20:01 ObnubiladO

@ObnubiladO it has been some time since this issue was raised. I am unable to replicate the issue on the same version of Chocolatey GUI.

Is this still an issue?

pauby avatar Apr 16 '24 12:04 pauby

ChocolateyGUI has been working fine up until today. I received the same error as ObnubiladO. Oddly enough, I have ChocolateyGUI installed on another identical Windows Server where it works fine.

mchin-rch avatar Jun 19 '24 13:06 mchin-rch

I reinstalled ChocolateyGUI just now and it actually works for me now. Same PC, same OS, so I don't know what fixed it.

I'm guessing it had something to do with a Windows update or some Windows process.

ObnubiladO avatar Jun 19 '24 13:06 ObnubiladO

@mchin-rch Given what was said above by @ObnubiladO, this may well be a Windows Update causing it.

pauby avatar Jun 19 '24 14:06 pauby

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward? This issue will be closed in 14 days if it continues to be inactive.

github-actions[bot] avatar Jul 20 '24 04:07 github-actions[bot]

Dear contributor,

As this issue seems to have been inactive for quite some time now, it has been automatically closed. If you feel this is a valid issue, please feel free to re-open the issue if / when a pull request has been added. Thank you for your contribution.

github-actions[bot] avatar Aug 04 '24 04:08 github-actions[bot]