Community
Participate
Working Groups
Steps to reproduce: Create a new project & configure it to use a CVS repo. Create a directory in the project root. Create a file inside this directory. Skipping this step will mask the problem. Sync the project. Locally delete the directory that was just created, including the file contained within it. Create a file in the project root with the same name as the directory that was just deleted. Select" Team>Sync with repository" from the context menu of the project. Expected behavior: An error dialog should appear, informing the user that a file cannot use the name of a directory that existed at the same location in the repository at one time, even if it has since been deleted. This is what happens if the creation of the original file inside the directory is skipped. Actual behavior: The Sync view pane appears but contains nothing. The following stack trace is written to the log: java.lang.ClassCastException: org.eclipse.team.internal.ccvs.core.resources.RemoteFolderTree at org.eclipse.team.internal.ccvs.ui.sync.CVSCatchupReleaseViewer.updateLabels(CVSCatchupReleaseViewer.java:493) at org.eclipse.team.internal.ui.sync.CatchupReleaseViewer.selectionChanged(CatchupReleaseViewer.java:585) at org.eclipse.jface.viewers.Viewer.fireSelectionChanged(Viewer.java:147) at org.eclipse.jface.viewers.StructuredViewer.updateSelection(StructuredViewer.java:1155) at org.eclipse.jface.viewers.StructuredViewer.setSelection(StructuredViewer.java:904) at org.eclipse.compare.structuremergeviewer.DiffTreeViewer.internalSetSelection(DiffTreeViewer.java:651) at org.eclipse.compare.structuremergeviewer.DiffTreeViewer.internalNavigate(DiffTreeViewer.java:556) at org.eclipse.compare.structuremergeviewer.DiffTreeViewer.navigate(DiffTreeViewer.java:511) at org.eclipse.compare.structuremergeviewer.DiffTreeViewer.initialSelection(DiffTreeViewer.java:355) at org.eclipse.compare.structuremergeviewer.DiffTreeViewer.inputChanged(DiffTreeViewer.java:341) at org.eclipse.team.internal.ui.sync.CatchupReleaseViewer.inputChanged(CatchupReleaseViewer.java:518) at org.eclipse.jface.viewers.ContentViewer.setInput(ContentViewer.java:234) at org.eclipse.jface.viewers.StructuredViewer.setInput(StructuredViewer.java:875) at org.eclipse.compare.CompareViewerSwitchingPane.setInput(CompareViewerSwitchingPane.java:261) at org.eclipse.compare.CompareEditorInput.createContents(CompareEditorInput.java:522) at org.eclipse.team.internal.ui.sync.SyncCompareInput.createContents(SyncCompareInput.java:99) at org.eclipse.team.internal.ui.sync.SyncView.showSync(SyncView.java:370) at org.eclipse.team.internal.ccvs.ui.actions.SyncAction.execute(SyncAction.java:35) at org.eclipse.team.internal.ccvs.ui.actions.CVSAction.run(CVSAction.java:76) at org.eclipse.ui.internal.PluginAction.runWithEvent(PluginAction.java:210) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(ActionContributionItem.java(Compiled Code)) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(ActionContributionItem.java(Compiled Code)) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(ActionContributionItem.java(Compiled Code)) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:1160) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:775) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:462) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:248) at org.eclipse.core.launcher.Main.run(Main.java:698) at org.eclipse.core.launcher.Main.main(Main.java:534)
Readme: workaround is to commit directory deletion first.
If the sync works, then select the resource in question and the error should occur.
Reopening
Thsi code no longer exists