refactor(database): access the library through EF Core

SongRepository uses Entity Framework Core instead of hand-written SQL. The
table and column names stay the same, so existing libraries open unchanged.
The duration rule moves into the repository, and a duplicate Openverse id
now surfaces as DbUpdateException. Libraries from before the Openverse
import, which lack the OpenverseId column, are no longer upgraded.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
fraujulianandClaude Fable 5.2 committed 2026-11-23 14:40:12 +01:00
1 parent 7cdc3b3a41
commit 65743279b1
5 files changed
+107 -121

No files matched your search

+1 -1
View File
@@ -9,7 +9,7 @@
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Data.Sqlite" Version="10.0.15" />
<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="10.0.15" />
<PackageReference Include="NAudio" Version="3.3.0" />
<PackageReference Include="TagLibSharp" Version="2.3.0" />
<PackageReference Include="WPF-UI" Version="4.3.0" />