The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to remove commit that does not exists but it listed on web ?

R
September 28, 2020

So the situation is like this(web):

2020-09-28 21_21_36-bedstar _ bedstar — Bitbucket.png

This is what I see on a WEB. commit 7d00(A) is seen there and was done via WEB interface - unfortunately, it does have changes from 3f3f(C) as child. Commit f513(B) has changes from C too.

Commit C and B was done via HTTPS and SSH.

There is no branch but web states branch might be (D) - but it is not,

On a console, I did perform this. I do not see 7d00 - even for a rebase.

Any idea what to do?

$git fetch origin
$git checkout origin/master
$git reset --hard origin
HEAD is now at f513.......

$git branch
* master

$git log --all --oneline
* f513 (HEAD -> master, origin/master, origin/HEAD) XXXX
* 3f3f XXXX
* 8bfe XXXX
* 5c02 XXXX
* ad8e XXXX

### did try - but no help - cannot see 7d00
$git fsck --lost-found
$git fsck --unreachable

 

1 answer

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

1 vote
Jimmy Seddon
Community Champion
September 28, 2020

Hi @R,

This is a very interesting situation.  Looking at the image it really looks like some how you have managed to get an orphaned commit.

Have you tried running:

gitk

or:

git log --graph --reflog

Either of those might help you find the missing commit locally.  I think once you have found it that will make it easier to be able to get the changes included in the master branch.

I hope that helps!

-Jimmy

R
September 28, 2020

Thanks for the reply. rlog and gitk just point me to f513(B), both are on the master branch and both have parent 3f3f(C). Repo is in fast-forward mode. It is not possible to see commit 7d00(A) after clone. Interesting is that when there was autotaging - it did tag this commit(A), but after checking logs it does tag previous one(B) - but the tag A on web GUI shows correctly. 

Jimmy Seddon
Community Champion
September 29, 2020

That's really weird!?  It might be worth putting in a ticket to Atlassian Support to have them look at the logs on the back end.

TAGS
AUG Leaders

Atlassian Community Events