`direnv` doesn't load envs properly (iTerm2, Terminal, and other apps work fine)
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 65.1k
- Forks
- 5.6k
- PR merge metrics
- PR metrics pending
Description
Dupe Check
- I have searched Warp bugs and there are no duplicates
Describe the bug
I have direnv installed on my machine and it loads envs properly in any terminal apps except Warp.
Note, Warp is using the same shell (zsh) as the other terminal apps I tried (VS Code, iTerm2, PyCharm).
To reproduce
- Install
direnv(/opt/homebrew/bin/direnv) - Init
direnvvia~/.zshrc(eval "$(direnv hook zsh)") - Create a
.envrcwith envs inside a directory and switch to the directory direnv allow .(it printsdirenv: loading ~/dstack/.envrc)- WHenever I run
direnv status, it printsLoaded RC path <REDACTED>/.envrc- confirming thatdirenvis installed properly
==
- When I switch to this folder via Warp, it doesn't print
direnv: loading <REDACTED>/.envrcand envs are not loaded; when I use other terminal apps (VS Code, iTerm2, PyCharm), and switch to the folder, it does printdirenv: loading <REDACTED>/.envrcand envs are loaded.
Expected behavior
Warp should work just as other Terminal apps (VS Code, iTerm2, PyCharm) and load envs from .envrcS
Screenshots
No response
Operating system
MacOS
Operating system and version
MacOS Sanoma 14.4.1 (23E224)
Shell Version
zsh 5.9 (arm-apple-darwin21.3.0)
Current Warp version
v0.2024.05.28.08.02.stable_00
Regression
Yes, this bug started recently or with an X Warp version
Recent working Warp date
No response
Additional context
No response
Does this block you from using Warp daily?
Yes, this issue prevents me from using Warp daily.
Is this a Warp specific issue? (i.e. does it happen in Terminal, iTerm, Kitty, etc.)
Yes, this I confirmed this only happens in Warp, not other terminals.
Warp Internal (ignore): linear-label:b9d78064-c89e-4973-b153-5178a31ee54e
None
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the issue in Warp with zsh, the ~/.zshrc direnv hook, and a directory containing an approved .envrc; compare the output with another terminal. Use direnv status and the expected direnv: loading message to verify that switching directories loads the environment in Warp.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust, zsh
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100