dotnet / dotnet/ef6tools

Designer failing on EF 6.5.1

Open
#65 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
36
Forks
24
PR merge metrics
No merged PRs in 30d

Description

So I know that getting the EDMX designer working with Microsoft.Data.SqlClient in EF 6.5.1 has not been a priority. However, the other day I was able to get the error message I usually get when attempting it to spit out a stack trace.

```
************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at Microsoft.Data.Entity.Design.VersioningFacade.LegacyProviderWrapper.LegacyDbProviderServicesWrapper.GetDbProviderManifest(String manifestToken)
at System.Data.Entity.Core.Common.DbProviderServices.GetProviderManifest(String manifestToken)
at System.Data.Entity.Core.Metadata.Edm.StoreItemCollection.Loader.InitializeProviderManifest(Action`3 addError)
at System.Data.Entity.Core.SchemaObjectModel.Schema.HandleAttribute(XmlReader reader)
at System.Data.Entity.Core.SchemaObjectModel.SchemaElement.ParseAttribute(XmlReader reader)
at System.Data.Entity.Core.SchemaObjectModel.SchemaElement.Parse(XmlReader reader)
at System.Data.Entity.Core.SchemaObjectModel.Schema.HandleTopLevelSchemaElement(XmlReader reader)
at System.Data.Entity.Core.SchemaObjectModel.Schema.InternalParse(XmlReader sourceReader, String sourceLocation)
at System.Data.Entity.Core.SchemaObjectModel.Schema.Parse(XmlReader sourceReader, String sourceLocation)
at System.Data.Entity.Core.SchemaObjectModel.SchemaManager.ParseAndValidate(IEnumerable`1 xmlReaders, IEnumerable`1 sourceFilePaths, SchemaDataModelOption dataModel, AttributeValueNotification providerNotification, AttributeValueNotification providerManifestTokenNotification, ProviderManifestNeeded providerManifestNeeded, IList`1& schemaCollection)
at System.Data.Entity.Core.Metadata.Edm.StoreItemCollection.Loader.LoadItems(IEnumerable`1 xmlReaders, IEnumerable`1 sourceFilePaths)
at System.Data.Entity.Core.Metadata.Edm.StoreItemCollection.Init(IEnumerable`1 xmlReaders, IEnumerable`1 filePaths, Boolean throwOnError, IDbDependencyResolver resolver, DbProviderManifest& providerManifest, DbProviderFactory& providerFactory, String& providerInvariantName, String& providerManifestToken, Memoizer`2& cachedCTypeFunction)
at System.Data.Entity.Core.Metadata.Edm.StoreItemCollection..ctor(IEnumerable`1 xmlReaders, ReadOnlyCollection`1 filePaths, IDbDependencyResolver resolver, IList`1& errors)
at System.Data.Entity.Core.Metadata.Edm.StoreItemCollection.Create(IEnumerable`1 xmlReaders, ReadOnlyCollection`1 filePaths, IDbDependencyResolver resolver, IList`1& errors)
at Microsoft.Data.Entity.Design.Model.Validation.RuntimeMetadataValidator.ValidateStoreModel(EntityDesignArtifact designArtifact)
at Microsoft.Data.Entity.Design.Model.Validation.RuntimeMetadataValidator.ValidateArtifactSet(EFArtifactSet artifactSet, Boolean forceValidation, Boolean validateMsl, Boolean runViewGen)
at Microsoft.Data.Entity.Design.Model.EntityDesignArtifact.DetermineIfArtifactIsStructurallySafe()
at Microsoft.Data.Entity.Design.Model.EntityDesignArtifact.DetermineIfArtifactIsDesignerSafe()
at Microsoft.Data.Entity.Design.VisualStudio.Model.VSArtifact.DetermineIfArtifactIsDesignerSafe()
at Microsoft.Data.Entity.Design.Model.EFArtifact.get_IsDesignerSafe()
at Microsoft.Data.Entity.Design.EntityDesigner.CustomSerializer.EntityModelToDslModelTranslatorStrategy.TranslateModelToDslModel(EFObject modelElement, Partition partition)
at Microsoft.Data.Entity.Design.EntityDesigner.MicrosoftDataEntityDesignSerializationHelper.LoadModel(SerializationResult serializationResult, Partition partition, String fileName, ISchemaResolver schemaResolver, ValidationController validationController, ISerializerLocator serializerLocator)
at Microsoft.Data.Entity.Design.EntityDesigner.MicrosoftDataEntityDesignSerializationHelper.LoadModelAndDiagram(SerializationResult serializationResult, Partition modelPartition, String modelFileName, Partition diagramPartition, String diagramFileName, ISchemaResolver schemaResolver, ValidationController validationController, ISerializerLocator serializerLocator)
at Microsoft.Data.Entity.Design.Package.MicrosoftDataEntityDesignDocDataBase.Load(String fileName, Boolean isReload)
at Microsoft.VisualStudio.Modeling.Shell.ModelingDocData.LoadDocData(String fileName, Boolean isReload)
at Microsoft.Data.Entity.Design.Package.MicrosoftDataEntityDesignDocData.LoadDocData(String fileName, Boolean isReload)
at Microsoft.VisualStudio.Modeling.Shell.DocData.ReloadDocDataWorker(UInt32 flags)
at Microsoft.VisualStudio.Modeling.Shell.DocData.OnFileChangeTimerTick(Object sender, EventArgs e)
at System.Windows.Forms.Timer.OnTick(EventArgs e)
at System.Windows.Forms.Timer.TimerNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
```

I thought maybe it would help track the issue down. I'd love to help... are there any instructions for how to build & install a custom version of the designer in VS?

I can repro this NRE consistently, so I'm happy to help any way I can. Thanks!

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.