-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
Annotate EF Core for nullable reference types #19007
Comments
Consider specifically the scenario in #19443 when working on this. |
Tag: C# nullable reference types |
Note: for LINQ async operators (e.g. FirstOrDefaultAsync): dotnet/roslyn#45993 (but depends on C# 9) |
Annotates Model, Property, Navigation, Key, Index, and all their extensions. Part of #19007
Annotates Model, Property, Navigation, Key, Index, and all their extensions. Part of #19007
Annotates Model, Property, Navigation, Key, Index, and all their extensions. Part of #19007
Annotates Model, Property, Navigation, Key, Index, and all their extensions. Part of #19007
Part of dotnet#19007
Part of dotnet#19007
Part of dotnet#19007
Part of dotnet#19007
Fixes dotnet#24403, part of dotnet#19007
* Enable nullability warnings as errors * Remove all individual file #nullable enable Part of #19007
* Enable nullability warnings as errors * Remove all individual file #nullable enable Part of #19007
Not sure if this has been fixed already but I've ran across a rather strange error that might be easy to miss which I think is related to the ef core analyzer and nullability which causes CS8619 warnings. I reported the issue in the Roslyn repo (dotnet/roslyn#51886) because I didn't see that it was related to EF Core at first. Basically if you create an anonymous type from a type that has nullable ref types with a lambda expression and you then also call an async ef method in a loop like The same problem happens in both 5.0.4 and 6.0.0-preview.2.21154.2. |
Split off annotating tests to #24427 |
Note: #14150 tracks introducing nullability to non-public parts as well (i.e. annotate the entire codebase), and isn't currently planned for 5.0.This issue now tracks annotating the entire codebase for C# 8 NRTs.
/cc @rynowak @cartermp
Work status
Some specific leftovers we need to do:
nullablePublicOnly
to the compiler - but we use pubternal extensively. Making EF Core more trimming friendly may be an alternative. See Add nullablePublicOnly Roslyn Feature aspnetcore#29908.#nullable disable
and see if we can get rid of themThe text was updated successfully, but these errors were encountered: