Skip to content

ripgrep broken after upgrading to opencode 1.14.18 #23411

Closed as not planned
Closed as not planned

Description

@MajorP93

Description

I upgraded from opencode 1.4.10 to 1.14.18 which caused ripgrep errors appearing.

Since I upgraded opencode I can see error "ripgrep archive did not contain executable: /home/user/.cache/opencode/bin/ripgrep-YtaXXi/ripgrep-14.1.1-x86_64-unknown-linux-musl/rg" every time opencode tries to perform some search tasks.

Is this a known issue?
Is there anything that I can do to solve this issue?

Plugins

none

OpenCode version

1.14.18

Steps to reproduce

  1. upgrade to latest opencode release (1.14.18)
  2. clone any github repository that contains a codebase
  3. cd into that codebase
  4. run opencode and invoke /init
  5. opencode will start searching the codebase and the mentioned error will appear

Screenshot and/or share link

No response

Operating System

Ubuntu 24.04

Terminal

Terminator

Activity

  1. added
    coreAnything pertaining to core functionality of the application (opencode server stuff)
    on Apr 19, 2026
  2. github-actions commented on Apr 19, 2026

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

  3. MajorP93 commented on Apr 19, 2026

    @MajorP93
    Author

    Narrowed it down to opencode's auto-install of ripgrep.
    Not sure why this is not working.
    I was able to work around this issue by installing ripgrep system-wide from Ubuntu repository.
    I installed opencode via "curl -fsSL https://opencode.ai/install | bash" by the way.

  4. kagura-chen commented on Apr 19, 2026

    @kagura-chen
    Contributor

    I'd like to look into this.

    The extract helper in ripgrep.ts is wrapped with Effect.scoped, which means the temp directory created by makeTempDirectoryScoped is cleaned up the moment extract returns — before the caller can check fs.exists(extracted) or copy the binary. This causes the "archive did not contain executable" error on fresh installs (no cached rg binary yet).

    Fix: remove Effect.scoped from extract so the temp directory's lifetime extends to the caller's scope, or switch to a non-scoped temp directory with manual cleanup.

  5. removed
    bugSomething isn't working
    coreAnything pertaining to core functionality of the application (opencode server stuff)
    on May 3, 2026
  6. github-actions commented on Jul 5, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

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