Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stopping GUI Goose via the stop button does not terminate background processes #1062

Open
alecthomas opened this issue Feb 4, 2025 · 2 comments
Assignees
Labels
bug Something isn't working ui

Comments

@alecthomas
Copy link
Contributor

Describe the bug
Goose ran "pnpm start" on a Docusaurus site (even though I asked it to build it), which never terminates.

To Reproduce
Steps to reproduce the behavior:

  1. Tell Goose to run some process in the background.
  2. Click stop.

Expected behavior
Goose should terminate any processes started during execution.

Please provide following information:

  • OS & Arch: macOS Sequoia
  • Interface: GUI
  • Version: v1.0.0
  • Extensions enabled: Devloper
  • Provider & Model: "goose" (internal)
@salman1993 salman1993 added bug Something isn't working ui labels Feb 4, 2025
jasonkneen added a commit to jasonkneen/maverick that referenced this issue Feb 5, 2025
Fixes block#1062

Add logic to terminate background processes when the stop button is clicked.

* **ui/desktop/src/ChatWindow.tsx**
  - Add logic to terminate background processes in the `onStopGoose` function.
  - Update the `stop` function to include background process termination.

* **ui/desktop/src/ai-sdk-fork/call-custom-chat-api.ts**
  - Add a `stop` function to terminate background processes.

* **ui/desktop/src/main.ts**
  - Update the `stop-power-save-blocker` function to stop background processes.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/block/goose/issues/1062?shareId=XXXX-XXXX-XXXX-XXXX).
@michaelneale
Copy link
Collaborator

note it won't necessarily stop goosed - but should stop ones that the agent itself launched yes... which would be a problem as it isn't. related: #1075 as non trivial (but should kill/drop, as used to)

@alecthomas
Copy link
Contributor Author

FYI I don't think this is a GUI issue. I was just able to reproduce this with the CLI:

( O)> Run "cd docs && pnpm start"
I'll run that command using the shell tool:

─── shell | developer ──────────────────────────
command: cd docs && pnpm start



It seems we need to reinstall the dependencies. Let me try that:

─── shell | developer ──────────────────────────
command: cd docs && pnpm install && pnpm start


◓  Molting old code...                                                               ^CWe interrupted the existing call to developer__shell. How would you like to proceed?

( O)> 
Input error: EOF
Closing session. Recorded to /Users/aat/.config/goose/sessions/hd8DTqPn.jsonl

🐚 ~/dev/ftl $ ps xaw | grep pnpm
18725 s000  S      0:00.01 bash -c cd docs && pnpm install && pnpm start 2>&1
18859 s000  S      0:00.21 /Users/aat/Library/Caches/hermit/pkg/pnpm-9.15.5/pnpm start
19044 s000  R+     0:00.00 grep pnpm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working ui
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants