lucasg/Dependencies · info

The binary caching preference has been modified, you need to

Error message

The binary caching preference has been modified, you need to restart Dependencies for the modifications to be actually reloaded.

What it means

This is an informational WPF MessageBox shown by UserSettings.OnValidate, not a thrown exception. BinaryCacheOptionValue controls whether Dependencies caches parsed binaries; the cache engine is initialized at startup, so changing the value at runtime cannot take effect immediately. When the newly selected combo value differs from the stored setting, the user is told to restart for it to reload.

Source

Thrown at DependenciesGui/UserSettings.xaml.cs:231

			int TreeDepth = Dependencies.Properties.Settings.Default.TreeDepth;
			if (Int32.TryParse(TreeDepthValue.Text, out TreeDepth))
			{
				Dependencies.Properties.Settings.Default.TreeDepth = TreeDepth;
			}
			

			if (TreeBuildCombo.SelectedItem != null)
            {
                Dependencies.Properties.Settings.Default.TreeBuildBehaviour = TreeBuildCombo.SelectedItem.ToString();
            }

            if (BinaryCacheCombo.SelectedItem != null)
            {
                bool newValue = (bool) (new BinaryCacheOption()).ConvertBack(BinaryCacheCombo.SelectedItem, null, null, null);

                if (Dependencies.Properties.Settings.Default.BinaryCacheOptionValue != newValue)
                {
                    System.Windows.MessageBox.Show("The binary caching preference has been modified, you need to restart Dependencies for the modifications to be actually reloaded.");
                }

                Dependencies.Properties.Settings.Default.BinaryCacheOptionValue = newValue;
            }


            Dependencies.Properties.Settings.Default.Font = FontFamilyListItem.GetDisplayName(SelectedFontFamily);
            this.Close();
        }

        private bool SelectListItem(System.Windows.Controls.ListBox list, object value)
        {
            ItemCollection itemList = list.Items;

            // Perform a binary search for the item.
            int first = 0;
            int limit = itemList.Count;

View on GitHub (pinned to 1997a40000)

Solutions

  1. Simply restart Dependencies after changing the setting so the cache engine reinitializes.
  2. If the prompt is undesirable, refactor BinaryCacheOption to hot-reload (dispose/rebuild the cache) so a restart is not required.
  3. Verify the setting persisted (Settings.Default.BinaryCacheOptionValue) so the restart actually picks up the new value.
  4. Confirm BinaryCacheCombo is bound to the expected BinaryCacheOption values so ConvertBack returns a meaningful bool.
Defensive patterns

Strategy: validation

Validate before calling

bool newValue = (bool)(new BinaryCacheOption()).ConvertBack(BinaryCacheCombo.SelectedItem, null, null, null);
bool changed = Dependencies.Properties.Settings.Default.BinaryCacheOptionValue != newValue;
// only show the restart notice (or trigger a hot reload) when `changed` is true

Prevention

When it happens

Trigger: The user opens the Settings dialog, changes the BinaryCacheCombo selection, and clicks OK. OnValidate converts the selection back to a bool via BinaryCacheOption.ConvertBack; if it differs from Settings.Default.BinaryCacheOptionValue the message is shown, then the new value is persisted and the dialog closes.

Common situations: Toggling binary caching on/off mid-session to save memory or speed up loads; first-time configuration on a fresh profile; expecting the change to apply to the already-loaded tree.

Related errors


AI-assisted analysis of lucasg/Dependencies@1997a40000 (2026-08-13). Data as JSON: /api/errors/7fecba6a7c37e4ab. Report an issue: GitHub.