-
Notifications
You must be signed in to change notification settings - Fork 548
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Running EF 6.x DbContext Generator in a .NET Standard 2.1 project fails #1384
Comments
@lajones Can you investigate this please. The issue may be that T4 templates don't work in .NET Standard 2.1 projects. |
Hi, The problem is actually when generating the template in a project with a new sdk-style project, even when the target is .NET Framework. The strange thing is that if you choose Debug T4 Template, it works! But not if you Run Custom Tool. Can you please give this immediate attention? I see similar issues raised and closed on the MS Dev Community (#703422 - not enough info) and here in issue #231 , yet it is still a problem in 6.3.0. Recreation is simple, creating an EF6.* model from DB in a project with the sdk format, then try to generate the template. I have attached an example. Edit: the data.Context.tt actually works fine in this example, but not the model template (data.tt). Thanks. |
Ping @lajones |
We have an internal bug on this: Feedback Item 972704. It's been transferred to the T4 team, but I haven't seen any movement on it for a while. I've pinged them again... |
Any updates on this? |
This issue has been closed because EF6 is no longer being actively developed. We are instead focusing on stability of the codebase, which means we will only make changes to address security issues. See the repo README for more information. |
When I run the
____.Context.tt
file generated from the EF 6.x DbContext Generator in a project that targets .NET Standard 2.1, it fails with the following exception and stack trace.Exception message:
Stack trace:
Steps to reproduce
.edmx
file in a .NET Framework project within Visual Studio 2019.Generator.tt
.Copy the resulting
Generator.tt
andGenerator.Context.tt
files into a .NET Standard 2.1 project.Generator.Context.tt
file.Further technical details
EF version: 6.3.0
Database Provider: EntityFramework.SqlServer
Operating system: Windows 10)
IDE: e.g. Visual Studio 2019 16.3.5
The text was updated successfully, but these errors were encountered: