Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FormSettings: InvalidOperationException IGitUICommands #11253

Closed
mstv opened this issue Oct 8, 2023 · 1 comment · Fixed by #11254
Closed

FormSettings: InvalidOperationException IGitUICommands #11253

mstv opened this issue Oct 8, 2023 · 1 comment · Fixed by #11254
Labels
type: regression regression, normally to latest official release
Milestone

Comments

@mstv
Copy link
Member

mstv commented Oct 8, 2023

In the current master, whenever I open the settings window, I get an exception here:

throw new InvalidOperationException("IGitUICommands should have been assigned");

I can push the rebased version anyway, but I feel iffy about pushing a version that I can only test partially.

Originally posted by @SlugFiller in #11239 (comment)

@mstv mstv changed the title SettingsDialog: InvalidOperationException IGitUICommands FormSettings: InvalidOperationException IGitUICommands Oct 8, 2023
@mstv
Copy link
Member Author

mstv commented Oct 8, 2023

FindForm() returns null because SettingsPageHeader.Parent is null at

>	ResourceManager.dll!ResourceManager.GitExtensionsControl.TryGetUICommands(out GitUIPluginInterfaces.IGitUICommands commands) Line 74	C#
 	GitUI.dll!GitUI.CommandsDialogs.SettingsDialog.Pages.ScriptsSettingsPage.ScriptsManager.get() Line 122	C#
 	GitUI.dll!GitUI.CommandsDialogs.SettingsDialog.Pages.ScriptsSettingsPage.SettingsToPage() Line 177	C#
 	GitUI.dll!GitUI.CommandsDialogs.SettingsDialog.SettingsPageBase.LoadSettings() Line 100	C#
 	GitUI.dll!GitUI.CommandsDialogs.FormSettings.LoadSettings() Line 68	C#
 	GitUI.dll!GitUI.CommandsDialogs.FormSettings.FormSettings_Shown(object sender, System.EventArgs e) Line 272	C#
 	[External Code]	
 	ResourceManager.dll!ResourceManager.GitExtensionsFormBase.WndProc(ref System.Windows.Forms.Message m) Line 106	C#
 	[External Code]	
 	GitUI.dll!GitUI.CommandsDialogs.FormSettings.ShowSettingsDialog.AnonymousMethod__0() Line 95	C#
 	GitCommands.dll!GitCommands.AppSettings.UsingContainer.AnonymousMethod__0() Line 191	C#
 	GitCommands.dll!GitCommands.Settings.SettingsContainer<GitCommands.Settings.DistributedSettings, GitCommands.Settings.GitExtSettingsCache>.LockedAction.AnonymousMethod__0() Line 29	C#
 	GitCommands.dll!GitCommands.SettingsCache.LockedAction.AnonymousMethod__0() Line 26	C#
 	GitCommands.dll!GitCommands.SettingsCache.LockedAction<object>(System.Func<object> action) Line 35	C#
 	GitCommands.dll!GitCommands.SettingsCache.LockedAction(System.Action action) Line 24	C#
 	GitCommands.dll!GitCommands.Settings.SettingsContainer<GitCommands.Settings.DistributedSettings, GitCommands.Settings.GitExtSettingsCache>.LockedAction(System.Action action) Line 21	C#
 	GitCommands.dll!GitCommands.AppSettings.UsingContainer(GitCommands.Settings.DistributedSettings settingsContainer, System.Action action) Line 185	C#
 	GitUI.dll!GitUI.CommandsDialogs.FormSettings.ShowSettingsDialog(GitUI.GitUICommands uiCommands, System.Windows.Forms.IWin32Window owner, GitUI.CommandsDialogs.SettingsDialog.SettingsPageReference initialPage) Line 93	C#
 	GitUI.dll!GitUI.GitUICommands.StartSettingsDialog.__Action|0() Line 915	C#
 	GitUI.dll!GitUI.GitUICommands.DoActionOnRepo(System.Windows.Forms.IWin32Window owner, System.Func<bool> action, bool requiresValidWorkingDir, bool changesRepo, System.EventHandler<GitUIPluginInterfaces.GitUIEventArgs> preEvent, System.EventHandler<GitUIPluginInterfaces.GitUIPostActionEventArgs> postEvent) Line 322	C#
 	GitUI.dll!GitUI.GitUICommands.StartSettingsDialog(System.Windows.Forms.IWin32Window owner, GitUI.CommandsDialogs.SettingsDialog.SettingsPageReference initialPage) Line 919	C#
 	GitUI.dll!GitUI.CommandsDialogs.FormBrowse.OnShowSettingsClick(object sender, System.EventArgs e) Line 1485	C#
 	[External Code]	
 	GitUI.dll!GitUI.CommandsDialogs.FormBrowse.ExecuteCommand(int cmd) Line 2132	C#
 	ResourceManager.dll!ResourceManager.GitExtensionsFormBase.ProcessHotkey(System.Windows.Forms.Keys keyData) Line 52	C#
 	GitUI.dll!GitUI.CommandsDialogs.FormBrowse.ProcessHotkey(System.Windows.Forms.Keys keyData) Line 2078	C#
 	ResourceManager.dll!ResourceManager.GitExtensionsFormBase.ProcessCmdKey(ref System.Windows.Forms.Message msg, System.Windows.Forms.Keys keyData) Line 68	C#
 	[External Code]	
 	ResourceManager.dll!ResourceManager.GitExtensionsControl.ProcessCmdKey(ref System.Windows.Forms.Message msg, System.Windows.Forms.Keys keyData) Line 112	C#
 	[External Code]	
 	GitUI.dll!GitUI.GitUICommands.StartBrowseDialog(System.Windows.Forms.IWin32Window owner, GitUI.CommandsDialogs.FormBrowse.BrowseArguments args) Line 1135	C#
 	GitUI.dll!GitUI.GitUICommands.RunBrowseCommand(System.Collections.Generic.IReadOnlyList<string> args) Line 1583	C#
 	GitUI.dll!GitUI.GitUICommands.RunCommandBasedOnArgument(System.Collections.Generic.IReadOnlyList<string> args, System.Collections.Generic.IReadOnlyDictionary<string, string> arguments) Line 1428	C#
 	GitUI.dll!GitUI.GitUICommands.RunCommand(System.Collections.Generic.IReadOnlyList<string> args) Line 1401	C#
 	GitExtensions.dll!GitExtensions.Program.RunApplication() Line 212	C#
 	GitExtensions.dll!GitExtensions.Program.Main() Line 115	C#

@mstv mstv added the type: regression regression, normally to latest official release label Oct 8, 2023
@mstv mstv added this to the vNext milestone Oct 8, 2023
@ghost ghost added the 🚧 status: in progress Issues which have associated PRs label Oct 8, 2023
@ghost ghost removed the 🚧 status: in progress Issues which have associated PRs label Oct 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: regression regression, normally to latest official release
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant