fix: initialize sqlite provider for migration
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="8.0.4" />
|
||||
<PackageReference Include="Microsoft.Data.Sqlite.Core" Version="8.0.4" />
|
||||
<PackageReference Include="Microsoft.Data.Sqlite" Version="8.0.4" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="8.0.4">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
|
||||
@@ -37,6 +37,8 @@ public sealed class SqliteToPostgresMigrationService
|
||||
string sqliteDbPath,
|
||||
CancellationToken cancellationToken = default)
|
||||
{
|
||||
SQLitePCL.Batteries_V2.Init();
|
||||
|
||||
if (string.IsNullOrWhiteSpace(sqliteDbPath))
|
||||
{
|
||||
throw new ArgumentException("SQLite database path is required.", nameof(sqliteDbPath));
|
||||
|
||||
Reference in New Issue
Block a user