brz push deletes commits in the git repo when there is a conflict
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Breezy |
Fix Released
|
Critical
|
Jelmer Vernooij | ||
3.0 |
Triaged
|
Critical
|
Jelmer Vernooij |
Bug Description
Steps to reproduce the bug:
- Create a new git repo in github with one text file and at least one commit.
- Open two terminals. In the first terminal use git to clone the repo, in the secondary terminal use brz branch git+ssh://whatever with the same repo.
- In the git terminal, modify the first line in the text file, commit the change and run git push.
- In the breezy terminal, modify the same line (with different content) in the same file, commit the change and run brz push. You will see something like "Pushed up to revision 2" with no error.
- In the git terminal, run git pull. It will show something like " + f3b6f48...39c9e78 master -> origin/master (forced update)". Your git commit is not in the remote git repo anymore.
Breezy shouldn't use push force without asking the user first or showing an error when there is a conflict.
Changed in brz: | |
status: | New → Triaged |
importance: | Undecided → Critical |
milestone: | none → 3.1.0 |
assignee: | nobody → Jelmer Vernooij (jelmer) |
I don't see evidence this deletes the commit. It appears to only change the branch tip. If the commit has been deleted, "git show $COMMIT" will report "bad object".