goose icon indicating copy to clipboard operation
goose copied to clipboard

feat: session management

Open Kvadratni opened this issue 1 year ago • 1 comments

This is a big one - adds session management as per design so far:

Update: even more refinement

https://github.com/user-attachments/assets/a50796f2-7226-467e-9a0e-ce6def8380f2

Sessions are matched up with directory goose window is currently in (so it is a shorter list) - unless you go to the menu. Clicking on it will open the session. Sessions are saved automatically.

There is a bit of a refactor of ChatWindow.tsx as part of this to make it simpler so it could do this.

Session Management:

  • Added functions to save, load, and clear chat sessions in sessionManager.ts.
  • Integrated session management in main.ts with IPC handlers for saving, loading, and listing sessions.
  • Updated preload.js to expose session management functions to the renderer process.
  • Modified LauncherWindow.tsx to include new session-related methods in the window.electron interface.

Kvadratni avatar Dec 04 '24 02:12 Kvadratni

Error: ENOENT: no such file or directory, mkdir '/Users/runner/.config/goose/sessions'
    at Object.mkdirSync (node:fs:1371:26)
    at Object.<anonymous> (/Users/runner/work/goose/goose/ui/desktop/.vite/build/main.js:3413:8)
    at Module._compile (node:internal/modules/cjs/loader:1484:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1564:10)
    at Module.load (node:internal/modules/cjs/loader:1295:32)
    at Module._load (node:internal/modules/cjs/loader:[11](https://github.com/block/goose/actions/runs/12248205568/job/34167398970?pr=402#step:5:12)11:12)
    at c._load (node:electron/js2c/node_init:2:16955)
    at cjsLoader (node:internal/modules/esm/translators:350:17)
    at ModuleWrap.<anonymous> (node:internal/modules/esm/translators:286:7)
    at ModuleJob.run (node:internal/modules/esm/module_job:234:25)

michaelneale avatar Dec 10 '24 02:12 michaelneale

New version of this in progress from @alexhancock

baxen avatar Feb 17 '25 20:02 baxen