Skip to content

Commit 2488065

Browse files
committed
Update the test and hero image
1 parent 46e3c7c commit 2488065

3 files changed

Lines changed: 24 additions & 5 deletions

File tree

assets/rlm-lab.png

-92 KB
Loading

docs/index.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,14 @@ Risk assessment with **40+ rules**, 6 approval modes, and full audit logging to
9797

9898
---
9999

100+
## 🖼️ RLM Research Lab
101+
102+
<p align="center">
103+
<img src="https://github.com/SuperagenticAI/rlm-code/raw/main/assets/rlm-lab.png" alt="RLM Research Lab" style="max-width: 100%; border-radius: 12px;">
104+
</p>
105+
106+
---
107+
100108
## 🚀 Quick Start
101109

102110
<div class="rlm-quickstart" markdown>

rlm_code/ui/persistent_shell.py

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def __init__(self, cwd: Path | None = None, shell: str | None = None):
6969
shell_base = Path(self.shell).name
7070
if shell_base == "zsh":
7171
rc_flags = ["--no-rcs", "--no-globalrcs"]
72-
elif shell_base in ("bash", "sh"):
72+
elif shell_base == "bash":
7373
rc_flags = ["--norc", "--noprofile"]
7474
else:
7575
rc_flags = []
@@ -114,10 +114,21 @@ def run(self, command: str, timeout: float = 30.0) -> ShellResult:
114114
wrapped = f'{command}\nprintf "{marker}:%s\\n" $?\n'
115115

116116
with self._write_lock:
117-
if self._proc.stdin is None:
118-
raise RuntimeError("Shell stdin is unavailable.")
119-
self._proc.stdin.write(wrapped)
120-
self._proc.stdin.flush()
117+
if self._proc.stdin is None or self._proc.poll() is not None:
118+
return ShellResult(
119+
command=command,
120+
output="Shell process is not running.\n",
121+
exit_code=127,
122+
)
123+
try:
124+
self._proc.stdin.write(wrapped)
125+
self._proc.stdin.flush()
126+
except (BrokenPipeError, OSError):
127+
return ShellResult(
128+
command=command,
129+
output="Shell process pipe is closed.\n",
130+
exit_code=127,
131+
)
121132

122133
lines: list[str] = []
123134
exit_code = 1

0 commit comments

Comments
 (0)