insomnia icon indicating copy to clipboard operation
insomnia copied to clipboard

Cannot sync repo with Git repo

Open bverkron opened this issue 2 years ago • 2 comments

I've tried multiple methods of getting a new Bitbucket repo to sync and it fails in various ways.

Clone method

If I try to initially create something in the project using the Clone feature I get Auth Failure even though the credentials are correct. It looks like it's injecting git+ at the start of the git url, which is strange because it does not do this when using the other method (below). Same things happen with a Github repo using the Git tab (instead of the GitHub tab).

image

I know the creds are correct because the auth works in the Setup Git Sync method (see below) and I can use them with the Bitbucket API to pull a list of files from a repo successfully...

image

Setup Git Sync method

When trying to use the git sync method within a design doc the initial setup and authentication works but I get a Could not find master error when trying to pull. The master branch is there on the remote so not sure if it's failing to find it locally because it failed the checkout or what. The log is quite vague.

image

This method works with a Github repo but the default branch name is main, maybe that's why?

bverkron avatar Jun 02 '23 22:06 bverkron

If I create another branch called main in the Bitbucket repo and then check that out via the Insomnia UI things seem to work from that point forward. I can then switch between the main and master branch and commit, pull, push, etc. So maybe it's just after the initial setup with the default branch name of master where things break? Not exactly sure what it is about what I did that made things work.

bverkron avatar Jun 02 '23 22:06 bverkron

I also get this if I don't do the above to "fix" the master error and I try to commit / push something.

Push rejected because it was not a simple fast-forward

image

And if I try to do a pull once in that state to try and get things in sync I get the following... image

bverkron avatar Jun 02 '23 23:06 bverkron

Any update on this?

I too frequently get push/pull failed messages and also I can see conflicts messages sometimes (Only I manage insomnia with git, but don't why I'm still getting conflicts and I don't see any way to resolve)

ravi-n4s avatar Sep 04 '23 05:09 ravi-n4s