dotnet / dotnet/efcore

Don't force NullabilityInfoContextSupport to be on

Open
#33,901 0 comments 1 reaction 1 assignee Claimed by @AndriySvyryd View on GitHub
area-aot area-model-building breaking-change
Dominant language
C#
Stars
14.8k
Forks
3.4k
PR merge metrics
PR metrics pending

Description

If the user uses a compiled model EF doesn't need `NullabilityInfoContext`.

Instead, we could throw when `NullabilityInfoContextSupport` is set to `false` and compiled model isn't being used.

```C#
AppContext.TryGetSwitch("System.Reflection.NullabilityInfoContext.IsSupported", out bool isSupported)
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.