Github: If the remote url contain the username and I push change them I get this error message: Empty password

Created on 16 Jun 2017  路  9Comments  路  Source: atom/github

Description

I can't push my commits from Atom if remote url contain the username, but git bash work correctly with git push command.
When I push them Atom ask password and I fill it but Atom say: (Unable to push, remote: Empty password...)

Steps to Reproduce

  1. Change files
  2. Stage files
  3. Commit (with message)
  4. Click Push Button (It show that, I have one commit.)
  5. Fill password field
  6. I got a message: Unable to push (remote: Empty password, fatal: Authentication failed for '[email protected]/...')

Expected behavior:

Ask user password (or not).
Push commit(s).

Actual behavior:

Ask user password.
Error message.

Reproduces how often:

If the remote url contain username.

Versions

Atom : 1.18.0
Electron: 1.3.15
Chrome : 52.0.2743.82
Node : 6.5.0

OS: Windows 10
git: 2.10.2.windows.1

Additional Information

I use bitbucket repo but I think It should be work with this.
It work corretly if I remove username from remote url, but I would be happier If it work in both version.

bug git

Most helpful comment

For folks using Bitbucket, does your remote URL have your username embedded i.e. https://[email protected]/USER/REPO? If so, can you update your remote to remove the username and try again?

git remote set-url origin https://bitbucket.org/USER/REPO

All 9 comments

The same here, but on macOS 10.12.15

Same with Bitbucket.
Just in case that helps, I'm also having problems with my repo in Gitkraken (this app just crashes whenever I try to open a repo with the remote pointing to Bitbucket).

For folks using Bitbucket, does your remote URL have your username embedded i.e. https://[email protected]/USER/REPO? If so, can you update your remote to remove the username and try again?

git remote set-url origin https://bitbucket.org/USER/REPO

Using Bitbucket, changing the remote url to NOT include the username as suggested by @rsese does seem to solve the issue. Atom prompts to enter both username and password, and is then able to push with no error.

@rsese thanks no more error but pain to enter user/pass every time, there is anyway to remember this ?

edit : fixed about enter user/pass by "git config --global credential.helper cache"

@rsese , @leshido : Thanks, It work.

Alright, this does seem to be a bug where we're not properly respecting the credentials stored in the remote URL. Thanks for the reports.

rsese Thanks - that worked.

I agree with others that eventually it would be nice if one could store the credentials locally so they don't have to be entered EACH AND EVERYTIME one does a Pull or a Push

@jano23: That's on our radar! In the meantime, if you have a git credential helper appropriate to your OS installed, it can be used to store password in your OS keychain or cache them for a certain amount of time.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

move[bot] picture move[bot]  路  3Comments

rsese picture rsese  路  4Comments

RafaelNGP picture RafaelNGP  路  4Comments

joshaber picture joshaber  路  4Comments

JamesChevalier picture JamesChevalier  路  4Comments