GreenDelta / olca-app

Source code of openLCA
openlca.org
Mozilla Public License 2.0
184 stars 41 forks source link

unable to pull data from collaborative server 2.0 - Remote does not have refs/heads/main available for fetch #372

Closed VDRoul closed 3 months ago

VDRoul commented 6 months ago

Hi,

I set up a collaborative server,and i'm looking now to use the client , but I am unable to make it work now that i'm looking to connect my database to the repository client side i get the following error " Remote does not have refs/heads/main available for fetch" and this is the extended log I found

09:56:52 ERROR o.o.app.collaboration.navigation.actions.Actions - Error pulling data org.eclipse.jgit.api.errors.TransportException: Remote does not have refs/heads/main available for fetch. at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:246) at org.openlca.git.actions.GitFetch.run(GitFetch.java:39) at org.openlca.git.actions.GitFetch.run(GitFetch.java:14) at org.openlca.app.collaboration.navigation.actions.Actions$GitRemoteRunner.run(Actions.java:151) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:122) Caused by: org.eclipse.jgit.errors.TransportException: Remote does not have refs/heads/main available for fetch. at org.eclipse.jgit.transport.FetchProcess.expandSingle(FetchProcess.java:427) at org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:169) at org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:103) at org.eclipse.jgit.transport.Transport.fetch(Transport.java:1462) at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:235) ... 4 common frames omitted

I am not under the impression that I am doing anything out of the ordinary, could you help me ? thanks a lot

SebastianGreve-GreenDelta commented 6 months ago

Does the repository contain commits? Currently if you pull a fresh repository without any commits, openLCA will also give the same error message

VDRoul commented 6 months ago

Hi @SebastianGreve-GreenDelta We've found the issue, as this was a clean install of OpenLCA, the git was automatically created with a "master" branch, whereas the OpenLCA App was looking for a "main" branch, we aligned the two and were able to make it work thanks