Skip to content
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

Code generation for custom data annotation attributes is broken #25127

Closed
lauxjpn opened this issue Jun 20, 2021 · 0 comments · Fixed by #25128
Closed

Code generation for custom data annotation attributes is broken #25127

lauxjpn opened this issue Jun 20, 2021 · 0 comments · Fixed by #25128
Labels
area-scaffolding closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. community-contribution customer-reported type-bug
Milestone

Comments

@lauxjpn
Copy link
Contributor

lauxjpn commented Jun 20, 2021

Custom data annotation attributes (e.g. the new MySqlCharSet attribute we just introduced for Pomelo) are not being emitted to the generated C# files.

This is an issue in 6.0 and in 5.0.

I'll provide a PR with a fix for 6.0.

@AndriySvyryd AndriySvyryd added this to the 6.0.0 milestone Jun 22, 2021
AndriySvyryd pushed a commit that referenced this issue Jun 25, 2021
* Fixes missing code generation output for custom data annotation attributes.
* Adds regression tests.

The two regression tests currently skip the assembly build process, because the two custom data annotation attributes do not exist in the generated assembly. If necessary, the `Microsoft.EntityFrameworkCore.Design.Tests` assembly could be added as a reference or additional source code files (containing the attributes) could be added to the build process.

Should be considered as a 5.0 backport.

(Feel free to directly change/edit this PR, if less time consuming than writing a review.)

Fixes #25127
@AndriySvyryd AndriySvyryd added the closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. label Jun 25, 2021
@ajcvickers ajcvickers modified the milestones: 6.0.0, 6.0.0-preview7 Jul 28, 2021
@ajcvickers ajcvickers modified the milestones: 6.0.0-preview7, 6.0.0 Nov 8, 2021
lauxjpn added a commit to lauxjpn/Pomelo.EntityFrameworkCore.MySql that referenced this issue Nov 9, 2021
lauxjpn added a commit to lauxjpn/Pomelo.EntityFrameworkCore.MySql that referenced this issue Nov 9, 2021
lauxjpn added a commit to PomeloFoundation/Pomelo.EntityFrameworkCore.MySql that referenced this issue Nov 9, 2021
* Remove remnants of workaround for dotnet/efcore#25127.

* Remove workaround for dotnet/efcore#24819.

* Remove workaround for dotnet/efcore#24806.

* Remove workaround for dotnet/efcore#19027.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-scaffolding closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. community-contribution customer-reported type-bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants