save progress

This commit is contained in:
StellaOps Bot
2026-01-03 12:41:57 +02:00
parent 83c37243e0
commit d486d41a48
48 changed files with 7174 additions and 1086 deletions

View File

@@ -34,6 +34,7 @@ using StellaOps.Scanner.Surface.FS;
using StellaOps.Scanner.Surface.Secrets;
using StellaOps.Scanner.Surface.Validation;
using StellaOps.Scanner.Triage;
using StellaOps.Scanner.Triage.Entities;
using StellaOps.Scanner.WebService.Diagnostics;
using StellaOps.Scanner.WebService.Determinism;
using StellaOps.Scanner.WebService.Endpoints;
@@ -155,7 +156,16 @@ builder.Services.AddSingleton<IBaselineService, BaselineService>();
builder.Services.AddSingleton<IActionablesService, ActionablesService>();
builder.Services.AddSingleton<ICounterfactualApiService, CounterfactualApiService>();
builder.Services.AddDbContext<TriageDbContext>(options =>
options.UseNpgsql(bootstrapOptions.Storage.Dsn));
options.UseNpgsql(bootstrapOptions.Storage.Dsn, npgsqlOptions =>
{
npgsqlOptions.MapEnum<TriageLane>();
npgsqlOptions.MapEnum<TriageVerdict>();
npgsqlOptions.MapEnum<TriageReachability>();
npgsqlOptions.MapEnum<TriageVexStatus>();
npgsqlOptions.MapEnum<TriageDecisionKind>();
npgsqlOptions.MapEnum<TriageSnapshotTrigger>();
npgsqlOptions.MapEnum<TriageEvidenceType>();
}));
builder.Services.AddScoped<ITriageQueryService, TriageQueryService>();
builder.Services.AddScoped<ITriageStatusService, TriageStatusService>();
@@ -503,6 +513,10 @@ app.UseExceptionHandler(errorApp =>
context.Response.ContentType = "application/problem+json";
var feature = context.Features.Get<IExceptionHandlerFeature>();
var error = feature?.Error;
if (error is not null)
{
app.Logger.LogError(error, "Unhandled exception.");
}
var extensions = new Dictionary<string, object?>(StringComparer.Ordinal)
{