Y
YugankNarula
Guest
Hi,
I have updated my windows 10 version and now while opening visual studio 2017 I am getting "Sequence contains no elements error".
Before up-gradation it was working fine. In ActivityLog.xml file it shows below error
Below is the error in Activitylog.Xml file.
<type>Error</type>
<source>Microsoft.VisualStudio.CommonIDE.ExtensibilityHosting.VsShellComponentModelHost</source>
<description>A MEF Component threw an exception at runtime: System.InvalidOperationException: Sequence contains no elements
 at System.Linq.Enumerable.First[TSource](IEnumerable`1 source)
 at Microsoft.VisualStudio.Composition.PartDiscovery.GetElementTypeFromMany(Type type)
 at Microsoft.VisualStudio.Composition.RuntimeComposition.RuntimeImport.get_ImportingSiteTypeWithoutCollection()
 at Microsoft.VisualStudio.Composition.RuntimeComposition.RuntimeImport.get_IsLazy()
 at Microsoft.VisualStudio.Composition.RuntimeComposition.RuntimeImport.get_LazyFactory()
 at Microsoft.VisualStudio.Composition.RuntimeExportProviderFactory.RuntimeExportProvider.GetValueForImportSite(RuntimePartLifecycleTracker importingPartTracker, RuntimeImport import)
 at Microsoft.VisualStudio.Composition.RuntimeExportProviderFactory.RuntimeExportProvider.RuntimePartLifecycleTracker.SatisfyImports()
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.SatisfyImmediateImports()
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.MoveNext(PartLifecycleState nextState)
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.TextDocData.SetSite(Object pUnkSite)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.RuntimeExportProviderFactory.RuntimeExportProvider.<>c__DisplayClass15_0.<GetExportedValueHelper>b__0()
Continue reading...
I have updated my windows 10 version and now while opening visual studio 2017 I am getting "Sequence contains no elements error".
Before up-gradation it was working fine. In ActivityLog.xml file it shows below error
Below is the error in Activitylog.Xml file.
<type>Error</type>
<source>Microsoft.VisualStudio.CommonIDE.ExtensibilityHosting.VsShellComponentModelHost</source>
<description>A MEF Component threw an exception at runtime: System.InvalidOperationException: Sequence contains no elements
 at System.Linq.Enumerable.First[TSource](IEnumerable`1 source)
 at Microsoft.VisualStudio.Composition.PartDiscovery.GetElementTypeFromMany(Type type)
 at Microsoft.VisualStudio.Composition.RuntimeComposition.RuntimeImport.get_ImportingSiteTypeWithoutCollection()
 at Microsoft.VisualStudio.Composition.RuntimeComposition.RuntimeImport.get_IsLazy()
 at Microsoft.VisualStudio.Composition.RuntimeComposition.RuntimeImport.get_LazyFactory()
 at Microsoft.VisualStudio.Composition.RuntimeExportProviderFactory.RuntimeExportProvider.GetValueForImportSite(RuntimePartLifecycleTracker importingPartTracker, RuntimeImport import)
 at Microsoft.VisualStudio.Composition.RuntimeExportProviderFactory.RuntimeExportProvider.RuntimePartLifecycleTracker.SatisfyImports()
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.SatisfyImmediateImports()
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.MoveNext(PartLifecycleState nextState)
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.EditorPackage.Initialize()
 at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.SetSite(IServiceProvider sp)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.ExportProvider.PartLifecycleTracker.GetValueReadyToExpose()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass53_0.<CreateExport>b__0()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.<>c__DisplayClass70_0`2.<GetExports>b__1()
 at System.Lazy`1.CreateValue()
 at System.Lazy`1.LazyInitValue()
 at System.Lazy`1.get_Value()
 at Microsoft.VisualStudio.Composition.ExportProvider.GetExportedValue[T]()
 at Microsoft.VisualStudio.ComponentModelHost.ComponentModel.GetService[T]()
 at Microsoft.VisualStudio.Editor.Implementation.EditorParts.get_ContentTypeRegistryService()
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.MakeLanguageServiceContentTypes(SettingsStore settingsStore)
 at Microsoft.VisualStudio.Editor.Implementation.LanguageServiceToContentTypeMapper.InitLanguageServiceToContentTypeMapper(IServiceProvider serviceProvider)
 at Microsoft.VisualStudio.Editor.Implementation.TextDocData.SetSite(Object pUnkSite)
--- End of stack trace from previous location where exception was thrown ---
 at Microsoft.VisualStudio.Composition.RuntimeExportProviderFactory.RuntimeExportProvider.<>c__DisplayClass15_0.<GetExportedValueHelper>b__0()
Continue reading...