git weirdness

Git is behaving a bit weirdly on Pycharm since today.

I created a new branch did some work there, and then went back to master. I was going to make a pull from the repository before merging my branch, but then I received this error:

 Error pulling origin: fatal: 'origin/origin/master' does not point to a commit


After a bit of proding I was able to merge my dev branch, and after that I succesfully pushed my commits to master. Pychar even merged the pending remote commits while I was "pushing" mine, so that's alright.

But I can't pull from the repository anymore. All attempts end up with the same error message:

 Error pulling origin: fatal: 'origin/origin/master' does not point to a commit


But git command line client works as expected (pulling from the remote when there is stuff to pull, or telling me that I'm already up-to-date if I am). But Pycharm it's not pulling anymore!

Where could I look to find out what's going on?

Thanks and regards,

Iván
9 comments
Comment actions Permalink
It seems that you have occasionally created a local branch with a name "origin/master". Please go to .git/refs/heads and post here, which files and directories you find there.

Also please post your .git/config.
0
Comment actions Permalink
Hi there Kirill.

.git/refs/heads it's empty.

And .git/config has:

[core]
        repositoryformatversion = 0
        filemode = false
        logallrefupdates = true
        autocrlf = false
[remote "origin"]
        url = https://yivi@bitbucket.org/arquiservi/pavimentosarquiservi.git
        fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
        remote = origin
        merge = refs/heads/master


If my git config is wrong, shouldn't "git pull" at the command line client fails as well? PyCharm is able to push, to fetch... but fails only at pull. :(

Thanks and regards!

I.-
0
Comment actions Permalink
.git/refs/heads it's empty.


That really can't be so. This is the place where Git stores references to branches it works with. So please double check.

Please attach idea.log as well (Help -> Reveal Log in...)
0
Comment actions Permalink
.git/refs/heads it's empty.

That really can't be so. This is the place where Git stores references to branches it works with. So please double check.


I'm very sorry. Missed "master" inside "heads". :P
Contents of master: "5a071f997665b97a552a2238200a224b21d9add2"

Idea.log attached.

I.-
idea.log (913KB)
0
Comment actions Permalink
I can't find the error you mentioned in the log. Could you please reproduce the problem and attach idea.log once again right after that?
0
Comment actions Permalink
Just reproduced again..

I see the corresponding line at the proper timestamp in the log, but no proper error seems to be generated that I can see...

pycharm.png

idea.log (930KB)
0
Comment actions Permalink
I've found the bug. Thanks for reporting the problem!
Will fix it ASAP.

I've fired a bugreport in our bugtracker: http://youtrack.jetbrains.com/issue/IDEA-91733
There you may find possible workarounds. Since you are pulling from the default tracked branch, you may find using Update Project instead of Git -> Pull a useful advice.
0
Comment actions Permalink
Thanks.

Just one comment: pull used to work through https. Only today after my branch/commit/branch-back/merge/commit cycle somehow I lost access to doing it through pycharm. Or maybe it's a regression from 2.6.2? I just updated this morning...

I can always do it through your workaround, or just use the command line client. Just that it is very slighly annoying (I have my keyboard shortcuts deeply memorized...).

Thanks a lot for your help! Let's hope it get's fixed for 2.6.3 and that is gets released soon!

Regards!
0
Comment actions Permalink
Yes, unfortunately it is a regression made in 2.6.2.

Btw, Update Project is more handy than Pull, also because it can temporary store your local changes (if you have any) and restore them after update.
0

Please sign in to leave a comment.