Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 347550 - 'Branch could not be created' error even if branch is successfully created
Summary: 'Branch could not be created' error even if branch is successfully created
Status: CLOSED FIXED
Alias: None
Product: EGit
Classification: Technology
Component: UI (show other bugs)
Version: 1.0   Edit
Hardware: PC Linux-GTK
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-28 13:44 EDT by James Blackburn CLA
Modified: 2013-09-29 11:26 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description James Blackburn CLA 2011-05-28 13:44:02 EDT
Eclipse EGit (Incubation)	1.0.0.201105261513	org.eclipse.egit.feature.group	Eclipse EGit
  Eclipse JGit (Incubation)	1.0.0.201105251218	org.eclipse.jgit.feature.group	Eclipse JGit

I had a local non-tracked file: .settings/.api_filters which existed in the commit I was trying to branch.  On branching from the history view, I got a 'Branch could not be created' error, however the branch was successfully created, just the checkout of the branch failed.

Branch could not be created
org.eclipse.jgit.api.errors.JGitInternalException: Checkout conflict with files: 
.settings/.api_filters
	at org.eclipse.jgit.api.CheckoutCommand.call(CheckoutCommand.java:211)
	at org.eclipse.egit.core.op.BranchOperation$1.run(BranchOperation.java:84)
	at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2344)
	at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2326)
	at org.eclipse.egit.core.op.BranchOperation.execute(BranchOperation.java:103)
	at org.eclipse.egit.ui.internal.branch.BranchOperationUI.run(BranchOperationUI.java:221)
	at org.eclipse.egit.ui.internal.repository.CreateBranchPage.createBranch(CreateBranchPage.java:400)
	at org.eclipse.egit.ui.internal.repository.CreateBranchWizard$1.run(CreateBranchWizard.java:93)
	at org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.java:464)
	at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:372)
	at org.eclipse.jface.wizard.WizardDialog.run(WizardDialog.java:1029)
	at org.eclipse.egit.ui.internal.repository.CreateBranchWizard.performFinish(CreateBranchWizard.java:87)
	at org.eclipse.jface.wizard.WizardDialog.finishPressed(WizardDialog.java:827)
	at org.eclipse.jface.wizard.WizardDialog.buttonPressed(WizardDialog.java:432)
	at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:624)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:240)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1258)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3586)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3207)
	at org.eclipse.jface.window.Window.runEventLoop(Window.java:825)
	at org.eclipse.jface.window.Window.open(Window.java:801)
	at org.eclipse.egit.ui.internal.history.command.CreateBranchOnCommitHandler.execute(CreateBranchOnCommitHandler.java:34)
	at org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:293)
	at org.eclipse.core.commands.Command.executeWithChecks(Command.java:476)
	at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:508)
	at org.eclipse.ui.internal.handlers.HandlerService.executeCommand(HandlerService.java:169)
	at org.eclipse.ui.internal.handlers.SlaveHandlerService.executeCommand(SlaveHandlerService.java:241)
	at org.eclipse.ui.internal.handlers.SlaveHandlerService.executeCommand(SlaveHandlerService.java:241)
	at org.eclipse.ui.internal.handlers.SlaveHandlerService.executeCommand(SlaveHandlerService.java:241)
	at org.eclipse.ui.menus.CommandContributionItem.handleWidgetSelection(CommandContributionItem.java:829)
	at org.eclipse.ui.menus.CommandContributionItem.access$19(CommandContributionItem.java:815)
	at org.eclipse.ui.menus.CommandContributionItem$5.handleEvent(CommandContributionItem.java:805)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1258)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3586)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3207)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2696)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2660)
	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2494)
	at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:674)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:667)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:123)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Caused by: org.eclipse.jgit.errors.CheckoutConflictException: Checkout conflict with files: 
.settings/.api_filters
	at org.eclipse.jgit.dircache.DirCacheCheckout.checkout(DirCacheCheckout.java:387)
	at org.eclipse.jgit.api.CheckoutCommand.call(CheckoutCommand.java:162)
	... 57 more
Comment 1 Robin Stocker CLA 2013-09-29 11:26:19 EDT
This has been fixed in the meantime, we now show a dialog with some options in case of checkout conflicts.