feat(ui): Listen-Einstellungen — Checkbox fuer serialize_on_file_overlap

Das Flag war bisher nur ueber MCP set_list_config erreichbar. UpdateListConfigDto
fuehrt es tri-state (null = gespeicherten Wert behalten), damit nur das
Listen-Modal es setzen/loeschen kann und kein anderer Aufrufer es per Omission
verliert.
This commit is contained in:
mika kuns
2026-08-27 10:15:17 +02:00
parent 24e1d648ee
commit 5cc99bfec6
9 changed files with 66 additions and 19 deletions
+2 -2
View File
@@ -104,8 +104,8 @@ public sealed class ConfigMcpTools
// Fields this tool doesn't expose but that live on the same row. They must survive every
// write here — ListRepository.SetConfigAsync copies the entity verbatim, so anything left
// at its default would silently reset (SerializeOnFileOverlap in particular has no UI
// affordance at all, so a reset is invisible until tasks stop serializing).
// at its default would silently reset (a SerializeOnFileOverlap reset only shows up as
// tasks no longer serializing, long after this write).
var hasUnrelatedSettings = existing is not null
&& (existing.SessionSkills is not null || existing.SerializeOnFileOverlap);
+7 -7
View File
@@ -545,13 +545,13 @@ public sealed class WorkerHub : Microsoft.AspNetCore.SignalR.Hub
var sessionSkills = SkillsToJson(dto.SessionSkills);
var verifyCommand = dto.VerifyCommand.NullIfBlank();
// Preserve SerializeOnFileOverlap: it has no UI/hub affordance yet (set via
// set_list_config or directly against ListConfigEntity), so a save from this path
// must not silently drop it -- neither by deleting the row nor by overwriting it.
// A null SerializeOnFileOverlap means "leave it as stored" — only the list-settings modal
// owns that field, so every other caller must not drop it (neither by deleting the row nor
// by overwriting it: SetConfigAsync copies the entity verbatim).
var existing = await repo.GetConfigAsync(dto.ListId);
var hasUnrelatedSettings = existing?.SerializeOnFileOverlap ?? false;
var serializeOnFileOverlap = dto.SerializeOnFileOverlap ?? existing?.SerializeOnFileOverlap ?? false;
if (model is null && systemPrompt is null && agentPath is null && dto.MaxTurns is null && sessionSkills is null && verifyCommand is null && !hasUnrelatedSettings)
if (model is null && systemPrompt is null && agentPath is null && dto.MaxTurns is null && sessionSkills is null && verifyCommand is null && !serializeOnFileOverlap)
{
await repo.DeleteConfigAsync(dto.ListId);
}
@@ -566,7 +566,7 @@ public sealed class WorkerHub : Microsoft.AspNetCore.SignalR.Hub
MaxTurns = dto.MaxTurns,
SessionSkills = sessionSkills,
VerifyCommand = verifyCommand,
SerializeOnFileOverlap = existing?.SerializeOnFileOverlap ?? false,
SerializeOnFileOverlap = serializeOnFileOverlap,
});
}
@@ -579,7 +579,7 @@ public sealed class WorkerHub : Microsoft.AspNetCore.SignalR.Hub
var repo = new ListRepository(ctx);
var config = await repo.GetConfigAsync(listId);
if (config is null) return null;
return new ListConfigDto(config.Model, config.SystemPrompt, config.AgentPath, config.MaxTurns, SkillsFromJson(config.SessionSkills), config.VerifyCommand);
return new ListConfigDto(config.Model, config.SystemPrompt, config.AgentPath, config.MaxTurns, SkillsFromJson(config.SessionSkills), config.VerifyCommand, config.SerializeOnFileOverlap);
}
public async Task<SetTaskStatusResultDto> SetTaskStatus(string taskId, string status)