fix: pass locale env to managed tmux sessions#690
Open
wierdbytes wants to merge 1 commit intogastownhall:mainfrom
Open
fix: pass locale env to managed tmux sessions#690wierdbytes wants to merge 1 commit intogastownhall:mainfrom
wierdbytes wants to merge 1 commit intogastownhall:mainfrom
Conversation
The supervisor runs as a launchd service (com.gascity.supervisor) which does not inherit the user's shell environment. This means LANG and LC_ALL are absent from managed tmux sessions, causing TUI tools like Claude Code to misrender UTF-8 glyphs (e.g. block characters in the statusline appear as diamonds). Add LANG, LC_ALL, and LC_CTYPE to the passthroughEnv whitelist, with a fallback to en_US.UTF-8 when LANG is unset.
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
LANG,LC_ALL,LC_CTYPEtopassthroughEnv()whitelisten_US.UTF-8whenLANGis unset (launchd supervisor)Problem
The supervisor runs as a launchd service (
com.gascity.supervisor) which does not inherit the user's shell environment.LANG/LC_ALLare absent from managed tmux sessions, causing TUI tools like Claude Code to misrender UTF-8 glyphs — e.g. block characters (▓,░) in the statusline appear as diamonds.The chain: launchd → gc supervisor (no LANG) →
passthroughEnv()skips LANG (empty) → tmux-eflags omit it → Claude Code starts without UTF-8 locale → ambiguous-width Unicode characters render incorrectly.Test plan
TestPassthroughEnvLANGFallback— verifies fallback toen_US.UTF-8when LANG is unsetTestPassthroughEnvLANGPassthrough— verifies user's LANG is preserved when setgc stop && gc start, thengc session attach mayor— Claude Code statusline renders▓░correctly