Repository navigation
fix: cap python grep fallback so unscoped search cannot OOM the host - #2116
Merged
Merged
Conversation
Agent grep with path=None walks from backend root `/`. Without ripgrep, deepagents' readline() on /proc/pagemap can grow RSS until the kernel OOM-kills Octop. Install rg in the images and replace the fallback at process start with a walk that skips virtual filesystems and bounds each read (#2101). Co-authored-by: Cursor <cursoragent@cursor.com>
7 of 15 tasks
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ripgrepin the official and FnOS Docker images so agentgrepuses the killable subprocess path by default.OctopServer.start(), replace deepagents' Python_python_searchwith a walk that skips/proc/sys/devand caps per-line / per-file reads, so a missingrgcan no longer grow RSS on/proc/*/pagemap([bug] 严重-内存溢出- #2101).developalready raisesNOFILEvia fix: raise fd limits and coalesce accept resource errors #2076 / [bug] 主进程 fd 软限 1024 耗尽:69 个 agent 的 memory.sqlite 常驻句柄占基线 96%,EMFILE 后重试风暴刷屏 18 万行,服务不可用直至手动重启 #2060.Test plan
uv run pytest tests/unit/backend/test_grep_safety.py -qmake precommit+ dashboard build) greenwhich rgis on PATHrgon PATH,FilesystemBackend(root_dir='/', virtual_mode=False)._python_search(...)on/procreturns immediately and RSS does not climbMade with Cursor