I have the same issue. I have an initialized git repository and get the error: The background agent requires a Git repository. Please initialize Git in this repository.
I am using remote ssh… Probably an issue with remote SSH/WSL
I am getting the same thing while trying to run from an initialized GitHub repo (My code is running on an Amazon Linux instance) but the OS shouldnt matter because it needs a github repo. Hopefully the team can provide a solution soon.
Also have this problem. I SSH to a remote AWS instance where my code resides. Git is initialized and the agent is able to make commits / cursor settings confirms git is connected / authorized. And yet the background agent says I don’t have git initialized. It doesn’t make much sense that it should be a problem that my environment is remote given that the background agent runs from my git repo.
This issue started to happen with us on Windows today. We were previously able to run Background Agents just fine.
Interestingly, we also get a “No environment.json” warning as well too–even though we indeed have a environment.json file at .cursor/environment.json. This is the first time we are seeing this warning as well.
I also get the “Git Not Initialized” error. The git repository is initialized, the regular Cursor/ VS Code git features are working, and I’ve provided Cursor with GitHub access. I get this whether or not I’m using a devcontainer. Running WSL/Ubuntu.