godot-git-plugin icon indicating copy to clipboard operation
godot-git-plugin copied to clipboard

Error 3: config value 'user.name' was not found in godot-git-plugin\src\git_plugin.cpp:GitPlugin::_commit#L103

Open Haha64142 opened this issue 7 months ago • 2 comments

Godot v4.4.1 I had entered my username and github PAT into the version control settings and connected to VCS. When I went to commit some changes, I was met with the error:

ERROR: core/variant/variant_utility.cpp:1098 - GitPlugin: Could not get default signature. Error -3: config value 'user.name' was not found in godot-git-plugin\src\git_plugin.cpp:GitPlugin::_commit#L103

I tried restarting godot. I also went to file explorer and checked that I had a .git file, so that means the repository was created.


I eventually managed to fix this. I went to the .git/config file and opened it in VS Code. After that, I Added the circled part to the config file, and it started working. I was able to commit and push to the repo Image



Edit 5/20/25 I was able to recreate the issue on my computer. Equipment:

  • Windows 10
  • Godot v4.4.1
  • Godot Git plugin v3.1.1

Steps:

  1. Create a new project
  2. Install Godot Git plugin
  3. Project -> Version Control -> Create/Override Version Control Metadata
  4. Click 'OK'
  5. Project -> Version Control -> Version Control Settings
  6. Click 'Connect to VCS'
  7. Enter your username and your github PAT for the password
  8. Go to the 'Commit' tab and stage all the changes
  9. Enter a Commit Message and click 'Commit Changes'

You should have the error message. Video of me replicating the error


However, I tried this on a separate laptop and it wouldn't repeat. I don't have git installed on my pc, but I do have git installed on my laptop, so that might me why it works on my laptop, but not my pc.

Haha64142 avatar May 19 '25 21:05 Haha64142

I experienced a similar issue today, on Linux. I do not have git installed on the machine and I am not using network features of the plugin at all, only using the plugin locally for version control. Your workaround of adding the user section to .git/config worked once I restarted Godot. Thank you for your assistance.

Wax-Replica avatar May 25 '25 21:05 Wax-Replica

I have realized that if you were to use git in your command line, it would give you these 2 errors saying that the values user.name and user.email could not be found. The only difference is that git would provide you with 2 commands that you could do to fix that. Those commands being:

git config --global user.name "Your Name"
git config --global user.email "[email protected]"

Now this error has become a matter of enhancement. If you had git installed, you could run the 2 commands mentioned above and that would fix it. If you don't have git installed, you could manually edit the files like I mentioned in the initial comment.

The best way to enhance this would be to have somewhere for the user to enter the 2 values, and with the error, you could prompt the user to enter the values into there

Haha64142 avatar May 31 '25 05:05 Haha64142