Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 344985

Summary: Git clone not helpful when passphrase is wrong
Product: [ECD] Orion Reporter: John Arthorne <john.arthorne>
Component: ClientAssignee: Malgorzata Janczarska <malgorzata.tomczyk>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: tomasz.zarna
Version: 0.2Keywords: polish
Target Milestone: 0.2   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Bug Depends on:    
Bug Blocks: 345168    

Description John Arthorne CLA 2011-05-06 11:11:53 EDT
0.2 M7

If I attempt to clone a git repository, but fail to enter a passphrase for my private key, I just see the error:

error An internal git error cloning git remote


This isn't very helpful. It should at least say in the message that my passphrase is wrong. Even better would be to reopen the "git clone" dialog with all the information filled in, so I don't have start over from scratch.

For what it's worth, I tried again on localhost, and I can see this message in my log, so we just need to get that message transferred to the client:

org.eclipse.jgit.errors.UnsupportedCredentialItem: ssh://git@github.com:22: Passphrase for identity
	at org.eclipse.jgit.transport.UsernamePasswordCredentialsProvider.get(UsernamePasswordCredentialsProvider.java:110)
	at org.eclipse.jgit.transport.CredentialsProviderUserInfo.promptPassphrase(CredentialsProviderUserInfo.java:98)
	at com.jcraft.jsch.UserAuthPublicKey.start(UserAuthPublicKey.java:116)
	at com.jcraft.jsch.Session.connect(Session.java:425)
	at org.eclipse.orion.server.jsch.SessionHandler.connect(SessionHandler.java:82)
	at org.eclipse.orion.server.git.GitSshSessionFactory.getSession(GitSshSessionFactory.java:54)
	at org.eclipse.jgit.transport.SshTransport.getSession(SshTransport.java:122)
	at org.eclipse.jgit.transport.TransportGitSsh$SshFetchConnection.<init>(TransportGitSsh.java:248)
	at org.eclipse.jgit.transport.TransportGitSsh.openFetch(TransportGitSsh.java:147)
	at org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:125)
	at org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:111)
	at org.eclipse.jgit.transport.Transport.fetch(Transport.java:1062)
	at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:136)
	at org.eclipse.jgit.api.CloneCommand.fetch(CloneCommand.java:165)
	at org.eclipse.jgit.api.CloneCommand.call(CloneCommand.java:114)
Comment 1 Malgorzata Janczarska CLA 2011-05-09 12:29:41 EDT
Done, but we should handle it better on UI, see Bug 345168.