fix(tasks): guard loop name length and surface loop ownership in the UI
Review follow-up: - Reject loop files whose frontmatter name exceeds MAX_TASK_NAME_LENGTH (80): task names are clamped at storage time, so a raw name longer than the limit could never match the stored task identity. The file is treated as malformed (definition: null) instead of creating an unreachable definition; MAX_TASK_NAME_LENGTH is now exported from project-config.js and shared with loops.js. - Surface loop-sourced tasks in the scheduled-tasks dialog: tasks carrying loopFile show a 'Managed by loop file <path>' note, and the enable toggle / edit / delete actions are disabled with an explanatory tooltip, since the file remains authoritative and would revert any such change. run-now stays available. New locale keys added to all 11 message files (i18n parity test enforces exact key sets). - ScheduledTask type gains an optional loopFile field (additive, unknown to older clients).
This commit is contained in:
@@ -396,6 +396,9 @@ export const dict: Record<I18nKey, string> = {
|
||||
'sessions.scheduledTasks.dialog.taskToggle.pauseAria': 'Wstrzymaj {taskName}',
|
||||
'sessions.scheduledTasks.dialog.taskToggle.enabled': 'Włączone',
|
||||
'sessions.scheduledTasks.dialog.taskToggle.paused': 'Wstrzymane',
|
||||
'sessions.scheduledTasks.dialog.loopFile.note': 'Zarządzane przez plik pętli {file}',
|
||||
'sessions.scheduledTasks.dialog.loopFile.toggleDisabled': 'Włączenie jest kontrolowane przez plik pętli; ustaw enabled w frontmatterze Markdown',
|
||||
'sessions.scheduledTasks.dialog.loopFile.actionsDisabled': 'Zadania pętli są konfigurowane w pliku Markdown .agents/loops',
|
||||
'sessions.scheduledTasks.editor.title.edit': 'Edytuj zaplanowane zadanie',
|
||||
'sessions.scheduledTasks.editor.title.new': 'Nowe zaplanowane zadanie',
|
||||
'sessions.scheduledTasks.editor.description': 'Skonfiguruj zadanie po stronie serwera, które tworzy nową sesję i wysyła prompt.',
|
||||
|
||||
Reference in New Issue
Block a user