Community
Participate
Working Groups
Tying to push to read-only repository throws TransportException that is wrapped with JGitInternalException with a very generic message. We should return an error with 403 HttpStatus and proper message. Client should use this status to redisplay the login prompt. org.eclipse.jgit.api.errors.JGitInternalException: Exception caught during execution of push command at org.eclipse.jgit.api.PushCommand.call(PushCommand.java:158) at org.eclipse.orion.server.git.servlets.PushJob.doPush(PushJob.java:81) at org.eclipse.orion.server.git.servlets.PushJob.run(PushJob.java:115) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54) Caused by: org.eclipse.jgit.errors.TransportException: https://gotom@github.com/gotom/gotom.git: not authorized at org.eclipse.jgit.transport.TransportHttp.connect(TransportHttp.java:446) at org.eclipse.jgit.transport.TransportHttp.openPush(TransportHttp.java:365) at org.eclipse.jgit.transport.PushProcess.execute(PushProcess.java:130) at org.eclipse.jgit.transport.Transport.push(Transport.java:1120) at org.eclipse.jgit.api.PushCommand.call(PushCommand.java:154)
This applies only to http connections.
Hopefully it should work now.