Bug with terminal cursor not reflecting .env changes immediately

I encountered a bug when using the terminal with the cursor. After modifying environment variables in the .env file, running docker-compose config in the terminal does not reflect the changes immediately. I have to open a new terminal and run docker-compose config to see the updates. This bug still exists in version 0.42.1. When tested in VSCode, this issue does not occur.

1 Like

Hi i encountered the same issue. is there any solution for this issue?

1 Like

Experiencing the same issue as well. I believe this bug was introduced fairly recently, as I had never experienced it before. Even after deleting my .env.local file it references values from my now deleted env file.

1 Like

Can confirm with the latest version too

1 Like

this happen to me… :frowning:

1 Like

same problem

1 Like

I’m sorry to complain here, but this is becoming a decision point for me to consider go back to use VScode. Many hours spent trying to fix an issue just to find out this was a problem with the tool I was using. The terminal does NOT work as expected. I simply can’t trust it is running with the right .env. I lost data and had to recover things from backup after it reused the previous .env file. I understand that the team have priorities, but this is happening for 8 MONTHS already. It is a serious problem and nothing was done about. Can some attention be given to this, please?

Hey , Facing the same issue here, anyone have a fix ?

This has been an issue I’ve had to deal with for many months now. My “solution” is to always restart the Cursor window which is very frustrating. Is there no attempt to fix this? @andrewh we would love some support here!

Had the same issue. Restarting cursor had no effect.

This was due to cursor saving some configuration in its workspace. I found the concerned workspace here /Library/Application Support/Cursor/User/workspaceStorage, asking cursor to locate me the exact folder associated to my project, as as each project has his own workspace. Once deleted, I restarted cursor and it worked.

But I guess the best and simplest solution is just to use dotenv