Closed santiagoprofumo closed 3 years ago
Remove global.json file. Replace the file content dependencies.props with
<Project>
<PropertyGroup>
<ComponentModelAnnotations>5.0.0</ComponentModelAnnotations>
<CoreFxVersion>5.0.2</CoreFxVersion>
<CSharpVersion>9.0</CSharpVersion>
<EfCoreVersion>5.0.6</EfCoreVersion>
<FrameworkVersion>net48</FrameworkVersion>
<JsonNetVersion>12.0.3</JsonNetVersion>
<NetStandardVersion>netstandard2.1</NetStandardVersion>
<NetCoreAppVersion>netcoreapp3.1</NetCoreAppVersion>
<NetCoreVersion>5.0.0</NetCoreVersion>
<NpgsqlVersion>5.0.6</NpgsqlVersion>
<ODataLibVersion>7.9.0</ODataLibVersion>
<OdataToEntityVersion>2.7.0</OdataToEntityVersion>
<SystemInteractiveAsyncVersion>5.0.0</SystemInteractiveAsyncVersion>
<TestSdkVersion>16.9.4</TestSdkVersion>
<Version>$(OdataToEntityVersion)</Version>
<XunitVersion>2.4.1</XunitVersion>
<XunitVSVersion>2.4.3</XunitVSVersion>
</PropertyGroup>
</Project>
First of all, thanks for your work!
I was trying to expose db using only connection string. I'm targeting netcore 3.1 (latest LTS version right now) so end up using OdataToEntity 2.5.1. Combining that to EFCore5 is throwing me an exception because this DbContextPool ctor is not longer available. I checked and with EFCore3.* it works but EFCore5 has a lot of improvements I need (like entities with no keys), so cannot downgrade from there.
https://github.com/voronov-maxim/OdataToEntity/blob/37e23ff105f720eca923a697d98091e6073ae19b/source/OdataToEntity.EfCore.DynamicDataContext/InformationSchema/SqlServerSchema.cs#L24
This may be already be solved on newer versions but for using those I should be targeting netcore 5, and for me is a no-go as it is not a LTS version.
Thanks again!