Workbench performance issue with large number of branches
Created originally on Bitbucket by C (Matthew Gabeler-Lee)
Originally reported investigating #3834, but was found to be a separate issue.
Workbench becomes unresponsive for several seconds on certain operations when working with a repository that has a very large number of branches.
Patch recommended by @yuja :
--- a/tortoisehg/hgqt/sync.py
+++ b/tortoisehg/hgqt/sync.py
@@ -245,7 +245,7 @@ class SyncWidget(QWidget, qtlib.TaskWidg
self.targetcombo.addItem(_('branch: ') + uname, ('--branch', name))
self.targetcombo.setItemData(self.targetcombo.count() - 1, name,
Qt.ToolTipRole)
- if ctx.thgbranchhead() and name == ctx.branch():
+ if name == ctx.branch() and ctx.thgbranchhead():
selIndex = self.targetcombo.count() - 1
for name in self.repo._bookmarks.keys():
uname = hglib.tounicode(name)
I'll follow up shortly to confirm if this patch fixes the issue.