question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

git push never completes when ssh key not named ~/.ssh/id_rsa

See original GitHub issue
  • VSCode Version: 1.51.1 (stable) and 1.52.0 (Insiders)
  • OS Version: Win 10 - 10.0.19041 build 19041
  • WSL 2: Ubuntu 20.04

Steps to Reproduce:

  1. Create new git commit
  2. Push using the built in Source Control panel Push never completes if ssh key is other name than ~/.ssh/id_rsa. SSH key is loaded and push works as expected in the terminal from the same session. But VSCode can’t complete git push. Renaming the ssh key to id_rsa solves the issue.

“Show Git Output”: Looking for git in: git Using git 2.29.2 from git

git rev-parse --git-dir Open repository: /home/<my>/<app>/<repo> git status -z -u git symbolic-ref --short HEAD git rev-parse master git rev-parse --symbolic-full-name master@{u} git rev-list --left-right master…refs/remotes/origin/master git for-each-ref --sort -committerdate --format %(refname) %(objectname) %(*objectname) git remote --verbose git config --get commit.template git check-ignore -v -z --stdin git status -z -u git symbolic-ref --short HEAD git rev-parse master git rev-parse --symbolic-full-name master@{u} git rev-list --left-right master…refs/remotes/origin/master git for-each-ref --sort -committerdate --format %(refname) %(objectname) %(*objectname) git remote --verbose git config --get commit.template git status -z -u git symbolic-ref --short HEAD git rev-parse master git rev-parse --symbolic-full-name master@{u} git rev-list --left-right master…refs/remotes/origin/master git for-each-ref --sort -committerdate --format %(refname) %(objectname) %(*objectname) git remote --verbose git config --get commit.template git status -z -u git symbolic-ref --short HEAD git rev-parse master git rev-parse --symbolic-full-name master@{u} git rev-list --left-right master…refs/remotes/origin/master git for-each-ref --sort -committerdate --format %(refname) %(objectname) %(*objectname) git remote --verbose git config --get commit.template git status -z -u git symbolic-ref --short HEAD git rev-parse master git rev-parse --symbolic-full-name master@{u} git rev-list --left-right master…refs/remotes/origin/master git for-each-ref --sort -committerdate --format %(refname) %(objectname) %(*objectname) git remote --verbose git config --get commit.template git status -z -u git symbolic-ref --short HEAD git rev-parse master git rev-parse --symbolic-full-name master@{u} git rev-list --left-right master…refs/remotes/origin/master git for-each-ref --sort -committerdate --format %(refname) %(objectname) %(*objectname) git remote --verbose git config --get commit.template git status -z -u git symbolic-ref --short HEAD git rev-parse master git rev-parse --symbolic-full-name master@{u} git rev-list --left-right master…refs/remotes/origin/master git for-each-ref --sort -committerdate --format %(refname) %(objectname) %(*objectname) git remote --verbose git config --get commit.template git add -A – . git -c user.useConfigOnly=true commit --quiet --allow-empty-message --file - git status -z -u git symbolic-ref --short HEAD git rev-parse master git rev-parse --symbolic-full-name master@{u} git rev-list --left-right master…refs/remotes/origin/master git for-each-ref --sort -committerdate --format %(refname) %(objectname) %(*objectname) git remote --verbose git config --get commit.template git push origin master:master

Does this issue occur when all extensions are disabled?: Yes/No

  • Unfortunately, I can’t test this as I only have a Linux based dev environment running in WSL 2 (on Win 10) so the WSL extension has to be enabled.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
hnlq715commented, Jan 12, 2021

When you rename your key… how do you configure git to use it, such that it works correctly in the terminal?

It works correctly in the terminal.

0reactions
hnlq715commented, Jan 12, 2021

same problem +1 I’m using WSL2, and everything goes fine when I changed the key name to id_rsa… Maybe vscode could inherit the SSH environment from bash?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Ask Question - Unix Stack Exchange
I have to repeatedly enter the following terminal commands in order to be able to push to a remote github repository.
Read more >
SSH key not working for git push unless recently logged in
To generate my SSH key, I did the following: $ ssh-keygen; Entered location and name and password ( /Users/username/.ssh/sitename.com ) ...
Read more >
How to tell git which private key to use? - Super User
I work on a machine (A) from which I git push to a server (B) that only accepts ssh key authentication. While my...
Read more >
PyCharm - Commit and push changes to Git repository
If you have not set your username, PyCharm will prompt you to specify it when you first attempt to commit changes. Open the...
Read more >
git-push Documentation - Git
When the command line does not specify where to push with the <repository> argument, branch.*.remote configuration for the current branch is consulted to ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found