Files
Aperant/apps/frontend/src/shared/i18n/locales/fr/terminal.json
T
Andy 63e2847fc5 Restore Terminal Session History on App Restart (#1515)
* auto-claude: subtask-1-1 - Add debug logging to main process session restoration flow

Add debug logging to trace outputBuffer handling in terminal session
restoration to help diagnose session history restoration issues:

- terminal-lifecycle.ts: Log outputBuffer lengths for passed vs stored
  sessions, and log buffer preview when returning for replay
- terminal-session-store.ts: Log outputBuffer info when getting sessions,
  updating sessions in memory, migrating from previous dates, and updating
  output buffer (throttled to avoid spam)

Uses debugLog from shared debug-logger utility - only outputs when DEBUG=true.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* auto-claude: subtask-1-2 - Add debug logging to renderer restoration flow

Add comprehensive debug logging to trace terminal session restoration:

- terminal-store.ts: Log restored terminal additions, buffer restoration,
  session fetching from disk, and restoration completion
- usePtyProcess.ts: Log PTY creation/restoration flow including skips,
  success, and error cases with retry logic
- useXterm.ts: Log xterm initialization, buffer replay, output callback
  registration, dimension ready events, and serialization

All logging uses debugLog/debugError from shared utils (only logs when
DEBUG=true environment variable is set).

* fix(terminal): ensure output buffer is restored before existence check

Move terminalBufferManager.set() BEFORE the early return in addRestoredTerminal().
This fixes a bug where terminal chat history was not restored on app restart
because:

1. If terminal already existed in store, function returned early
2. Buffer was never stored in terminalBufferManager
3. useXterm read empty buffer and displayed nothing

Now the buffer is always restored first, regardless of whether the terminal
already exists, ensuring chat history is visible after app restart.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix(terminal): initialize pendingClaudeResume during session restoration

Fix Claude resume timing race condition. The TERMINAL_PENDING_RESUME
IPC event was sent before the renderer's Terminal component mounted
its listener, causing the event to be lost.

Now addRestoredTerminal() initializes pendingClaudeResume from
session.isClaudeMode, so the renderer knows to trigger 'claude
--continue' when the terminal becomes active without relying on
IPC timing.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* auto-claude: subtask-3-3 - Add visual indicator for terminals with pending Claude resume

- Added pendingClaudeResume prop to TerminalHeader component
- Visual indicator shows cyan pulsing badge with RotateCcw icon
- Badge displays "Resume Available" text (collapses to icon on narrow terminals)
- Tooltip explains user can click to resume previous Claude session
- Added i18n translations for English and French
- Terminal.tsx passes pendingClaudeResume from terminal store to header

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix(terminal): address PR review findings

- Update pendingClaudeResume for existing terminals during re-restore
  to ensure deferred Claude resume works in project switch scenarios
- Remove sensitive terminal output preview from debug logs
- Add atomic getAndClear() method to prevent theoretical buffer data
  loss between get() and clear() operations

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-26 09:44:47 +01:00

46 lines
2.0 KiB
JSON

{
"expand": {
"expand": "Agrandir le terminal",
"collapse": "Reduire le terminal"
},
"resume": {
"pending": "Reprise disponible",
"pendingTooltip": "Cliquez pour reprendre la session Claude précédente"
},
"auth": {
"terminalTitle": "Auth: {{profileName}}",
"maxTerminalsReached": "Impossible d'ouvrir le terminal d'auth: nombre maximum de terminaux atteint. Fermez un terminal d'abord."
},
"worktree": {
"create": "Worktree",
"createNew": "Nouveau Worktree",
"existing": "Worktrees Terminal",
"taskWorktrees": "Worktrees de Taches",
"otherWorktrees": "Autres",
"createTitle": "Creer un Worktree Terminal",
"createDescription": "Creer un espace de travail isole pour ce terminal. Tout le travail se fera dans le repertoire du worktree.",
"name": "Nom du Worktree",
"namePlaceholder": "ma-fonctionnalite",
"nameRequired": "Le nom du worktree est requis",
"nameInvalid": "Le nom doit commencer et se terminer par une lettre ou un chiffre",
"nameHelp": "Lettres minuscules, chiffres, tirets et underscores (les espaces deviennent des tirets)",
"associateTask": "Lier a une Tache",
"selectTask": "Selectionner une tache...",
"noTask": "Pas de tache (worktree autonome)",
"createBranch": "Creer une Branche Git",
"branchHelp": "Cree la branche: {{branch}}",
"baseBranch": "Branche de Base",
"selectBaseBranch": "Selectionner la branche de base...",
"searchBranch": "Rechercher des branches...",
"noBranchFound": "Aucune branche trouvee",
"useProjectDefault": "Utiliser la valeur par defaut du projet ({{branch}})",
"baseBranchHelp": "La branche a partir de laquelle creer le worktree",
"openInIDE": "Ouvrir dans IDE",
"maxReached": "Maximum de 12 worktrees terminal atteint",
"alreadyExists": "Un worktree avec ce nom existe deja",
"deleteTitle": "Supprimer le Worktree?",
"deleteDescription": "Ceci supprimera definitivement le worktree et sa branche. Les modifications non committées seront perdues.",
"detached": "(détaché)"
}
}