Skip to content

Goose Session Panic on Startup #5197

@p5

Description

@p5

Describe the bug

I encounter a panic when trying to create a new session on v1.10.2. Everything worked in v1.8.0, but started breaking after the upgrade. Could reproduce in a clean container and after emptying ~/.config/goose.

To Reproduce
Steps to reproduce the behavior:

  1. Build and run the below container
  2. Configure your provider (I only have access to Copilot)
  3. Run goose or goose session
  4. See error

Expected behavior

I expected to be able to start a Goose session without encountering Rust panics.

Screenshots
See below log.

Please provide following information:

  • OS & Arch: Fedora 42 - X86_64
  • Interface: CLI
  • Version: v1.10.2
  • Extensions enabled: None
  • Provider & Model: GitHub Copilot, Grok code fast 1

Additional context

Repos/rsturla/mcp-server-rpm 
❯ goose       
starting session | provider: github_copilot model: grok-code-fast-1
    logging to /var/home/admin/.local/share/goose/sessions/20251016_021845.jsonl
    working directory: /var/home/admin/Repos/rsturla/mcp-server-rpm

Goose is running! Enter your instructions, or try asking what goose can do.

Context: ○○○○○○○○○○ 0% (0/131072 tokens)
( O)> Press Enter to send, Ctrl-J for new line

Closing session. Recorded to /var/home/admin/.local/share/goose/sessions/20251016_021845.jsonl

Repos/rsturla/mcp-server-rpm 
❯ goose --version
 1.8.0

Repos/rsturla/mcp-server-rpm 
❯ goose update   
WINDIR: <not set>
OSTYPE: linux-gnu
uname -s: Linux
uname -m: x86_64
PWD: /var/home/admin/Repos/rsturla/mcp-server-rpm
Detected OS: linux with ARCH x86_64
Downloading stable release: goose-x86_64-unknown-linux-gnu.tar.bz2...
Extracting goose-x86_64-unknown-linux-gnu.tar.bz2 to temporary directory...
Moving goose to /var/home/admin/.local/bin/goose
Moving temporal-service to /var/home/admin/.local/bin/temporal-service
Moving temporal CLI to /var/home/admin/.local/bin/temporal
Skipping 'goose configure', you may need to run this manually later

Repos/rsturla/mcp-server-rpm took 15s 
❯ goose --version
 1.10.2

Repos/rsturla/mcp-server-rpm 
❯ goose          

thread 'main' panicked at crates/goose-cli/src/session/mod.rs:136:26:
called `Result::unwrap()` on an `Err` value: Session not found
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Repos/rsturla/mcp-server-rpm 
❯ goose session

thread 'main' panicked at crates/goose-cli/src/session/mod.rs:136:26:
called `Result::unwrap()` on an `Err` value: Session not found
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Could reproduce on both the F43 host, and a F43 container with the below Containerfile:

FROM quay.io/fedora/fedora:43
ARG PYTHON_VERSION=3.14

ENV GOOSE_DISABLE_KEYRING=1

RUN --mount=type=cache,target=/var/cache \
    dnf install -y \
    zsh \
    git \
    jq \
    yq \
    make

RUN --mount=type=cache,target=/var/cache \
    dnf install -y \
    podman-remote \
    python${PYTHON_VERSION} \
    python${PYTHON_VERSION}-pip \
    nodejs \
    npm \
    libxcb

RUN ln -s /usr/bin/podman-remote /usr/bin/podman

RUN --mount=type=cache,target=/var/cache \
    dnf clean all

RUN useradd -ms /usr/bin/zsh vscode && \
    echo "vscode ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers

USER root
RUN mkdir -p /home/vscode && chown -R vscode:vscode /home/vscode

USER vscode
WORKDIR /home/vscode

RUN sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended --keep-zshrc && \
    git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-/home/vscode/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting && \
    git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-/home/vscode/.oh-my-zsh/custom}/plugins/zsh-autosuggestions

RUN curl -fsSL https://github.com/block/goose/releases/download/stable/download_cli.sh | CONFIGURE=false bash

Full backtrace:


thread 'main' panicked at crates/goose-cli/src/session/mod.rs:136:26:
called `Result::unwrap()` on an `Err` value: Session not found

Stack backtrace:
   0: anyhow::error::<impl anyhow::Error>::msg
   1: goose::session::session_manager::SessionManager::get_session::{{closure}}
   2: tokio::runtime::park::CachedParkThread::block_on
   3: tokio::runtime::handle::Handle::block_on
   4: tokio::runtime::scheduler::multi_thread::worker::block_in_place
   5: goose_cli::session::CliSession::new
   6: goose_cli::session::builder::build_session::{{closure}}
   7: goose_cli::cli::cli::{{closure}}
   8: goose::main::{{closure}}
   9: tokio::runtime::park::CachedParkThread::block_on
  10: tokio::runtime::context::runtime::enter_runtime
  11: tokio::runtime::runtime::Runtime::block_on
  12: goose::main
  13: std::sys::backtrace::__rust_begin_short_backtrace
  14: std::rt::lang_start::{{closure}}
  15: std::rt::lang_start_internal
  16: main
  17: __libc_start_call_main
  18: __libc_start_main_alias_1
  19: _start
stack backtrace:
   0:     0x556d813d6742 - <std::sys::backtrace::BacktraceLock::print::DisplayBacktrace as core::fmt::Display>::fmt::h46a716bba2450163
   1:     0x556d814043f3 - core::fmt::write::h275e5980d7008551
   2:     0x556d813d14e3 - std::io::Write::write_fmt::h561a66a0340b6995
   3:     0x556d813d6592 - std::sys::backtrace::BacktraceLock::print::hafb9d5969adc39a0
   4:     0x556d813d8ce2 - std::panicking::default_hook::{{closure}}::hae2e97a5c4b2b777
   5:     0x556d813d8ae5 - std::panicking::default_hook::h3db1b505cfc4eb79
   6:     0x556d813d9682 - std::panicking::rust_panic_with_hook::h409da73ddef13937
   7:     0x556d813d942a - std::panicking::begin_panic_handler::{{closure}}::h159b61b27f96a9c2
   8:     0x556d813d6c39 - std::sys::backtrace::__rust_end_short_backtrace::h5b56844d75e766fc
   9:     0x556d813d90bd - __rustc[4794b31dd7191200]::rust_begin_unwind
  10:     0x556d7dacd190 - core::panicking::panic_fmt::hc8737e8cca20a7c8
  11:     0x556d7dacd5b6 - core::result::unwrap_failed::h727108008d9f4c9b
  12:     0x556d7e43620e - tokio::runtime::park::CachedParkThread::block_on::h6d4600b1658266a7
  13:     0x556d7e535c95 - tokio::runtime::handle::Handle::block_on::h9774b0ca9ce9fac8
  14:     0x556d7e5cb781 - tokio::runtime::scheduler::multi_thread::worker::block_in_place::h956c4334e72d48db
  15:     0x556d7e694d66 - goose_cli::session::CliSession::new::hd67275afcd6f9266
  16:     0x556d7dc61837 - goose_cli::session::builder::build_session::{{closure}}::h489af6a2ac937d53
  17:     0x556d7dc33065 - goose_cli::cli::cli::{{closure}}::h37056f45d0ddab34
  18:     0x556d7dc7bd21 - goose::main::{{closure}}::h1e608445aa31f890
  19:     0x556d7dce4717 - tokio::runtime::park::CachedParkThread::block_on::h90ba70e6f85c6474
  20:     0x556d7e197211 - tokio::runtime::context::runtime::enter_runtime::hce8d4e5f993e8012
  21:     0x556d7e03c7d6 - tokio::runtime::runtime::Runtime::block_on::h8e9f6146dc5c4f75
  22:     0x556d7e39f3be - goose::main::h37c3ac309fbbf991
  23:     0x556d7e33be93 - std::sys::backtrace::__rust_begin_short_backtrace::heb255d3c1a1634e8
  24:     0x556d7e1460fd - std::rt::lang_start::{{closure}}::h437c1679743b1f49
  25:     0x556d813c5314 - std::rt::lang_start_internal::ha8ef919ae4984948
  26:     0x556d7e39f495 - main
  27:     0x7f0642d725b5 - __libc_start_call_main
  28:     0x7f0642d72668 - __libc_start_main_alias_1
  29:     0x556d7dad011e - _start
  30:                0x0 - <unknown>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions