-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Closed
Labels
Description
Environment
- Git Extensions 5.2.1.18061
- Build 0d74cfd
- Git 2.47.1.windows.1
- Microsoft Windows NT 10.0.26100.0
- .NET 8.0.14
- DPI 120dpi (125% scaling)
- Portable: False
Issue description
System.InvalidOperationException: Sequence contains more than one matching element
at System.Linq.ThrowHelper.ThrowMoreThanOneMatchException()
at System.Linq.Enumerable.TryGetSingle[TSource](IEnumerable`1 source, Func`2 predicate, Boolean& found)
at System.Linq.Enumerable.SingleOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
at GitUI.CommandsDialogs.RevisionFileTreeController.FindSubNode(TreeNodeCollection nodes, Queue`1 pathParts) in C:\projects\gitextensions\src\app\GitUI\CommandsDialogs\RevisionFileTreeController.cs:line 166
at GitUI.CommandsDialogs.RevisionFileTreeController.SelectFileOrFolder(NativeTreeView tree, String fileSubPath) in C:\projects\gitextensions\src\app\GitUI\CommandsDialogs\RevisionFileTreeController.cs:line 149
at GitUI.CommandsDialogs.RevisionFileTreeControl.LoadRevision(GitRevision revision) in C:\projects\gitextensions\src\app\GitUI\CommandsDialogs\RevisionFileTreeControl.cs:line 231
at GitUI.CommandsDialogs.FormBrowse.FillFileTree(GitRevision revision) in C:\projects\gitextensions\src\app\GitUI\CommandsDialogs\FormBrowse.cs:line 1230
at GitUI.CommandsDialogs.FormBrowse.RefreshSelection() in C:\projects\gitextensions\src\app\GitUI\CommandsDialogs\FormBrowse.cs:line 741
at GitUI.CommandsDialogs.FormBrowse.CommitInfoTabControl_SelectedIndexChanged(Object sender, EventArgs e) in C:\projects\gitextensions\src\app\GitUI\CommandsDialogs\FormBrowse.cs:line 1574
at System.Windows.Forms.TabControl.OnSelectedIndexChanged(EventArgs e)
at System.Windows.Forms.TabControl.WmSelChange()
at System.Windows.Forms.NativeWindow.Callback(HWND hWnd, MessageId msg, WPARAM wparam, LPARAM lparam)
I clicked on "File tree" for the selected file and it says "Sequence contains more than one matching element". It was my fault, I have some files starting with the space character in my repository.
Steps to reproduce
- Create a random file (e.g. "a.txt")
- Create a file with the same name and put the space character at the beginning (e.g. " a.txt")
- Commit these files
- Open "File Tree" for one of these files
Did this work in previous version of GitExtensions?
No response
Diagnostics
No response