You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG] IFS=… read ignores the prefix assignment (builtins don't see VAR=x builtin env) #308
strands-shell -c 'printf "a,b\n" | { IFS=, read x y; echo "[$x][$y]"; }'
strands-shell -c 'printf "a b\n" | { IFS=, read x y; echo "[$x][$y]"; }'
Expected Behavior
As in bash 5.2: [a][b] and [a b][]. The IFS=, applies to that read only.
Actual Behavior
[a,b][] and [a][b]. read splits on the shell's IFS and ignores the prefix assignment.
Additional Context
The single-command builtin path (src/exec.rs ~3547, builtins::lookup(...)) runs the builtin without applying expanded_env, so read reads IFS from proc.env (src/builtins/read.rs). This breaks IFS= read -r line and IFS=: read a b, two very common agent idioms. Once #307 lands, it also breaks IFS= read -r -d '' x, which then drops trailing newlines or whitespace.
Activity
fix: keep a prefix assignment on local from leaking into the caller (s…