To suppress the warning and avoid false-positive "pending changes," you can add this line to your DbContext
configuration:
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
{
optionsBuilder
.UseNpgsql("YourConnectionStringHere")
.ConfigureWarnings(warnings =>
warnings.Ignore(RelationalEventId.PendingModelChangesWarning));
}
This line
.ConfigureWarnings(warnings =>
warnings.Ignore(RelationalEventId.PendingModelChangesWarning));
tells EF Core to ignore the warning about pending model changes, allowing Update-Database to run without requiring a redundant migration.