0
Cannot Reproduce

Failed to fetch unit options for fuzzy finder/Graph can't be edited anymore

Delta5.1 2 years ago updated by Lazlo Bonin (Lead Developer) 2 years ago 3

Hello everyone,

I've got a big problem with bolt and it's currently not useable for me. At first it worked absolutely fine and saved me a lot of time and work. But a few weeks ago it suddenly stopped working after I imported a lot of new assets into the project. Importing GeNa even broke the whole project so I decided to backup my project with bolt - that's when I realised that Bolt was somehow corrupted or simply not working.


Backup didn't work and failed at some point. I've double checked the graphs: my previous made graphs all worked fine, even in the build but I'm now unable to set up new graphs. They remain completely blank and I can't add new nodes. There are only blank options like variables and the object the flow machine is attached to.


EDIT: Unity 2017.4.0f1 btw


I tried to update and rebuild the unit options which resulted in multiple errors and wouild abort the process. After updating Bolt (from Asset Store) the backup option now works correctly but I still can't build my unit options. I get the following errors:


Failed to fetch unit options for fuzzy finder (error log below).
Try rebuilding the unit options from 'Tools > Bolt > Build Unit Options'.

UnityEngine.UnityException: More than one 'Bolt.SceneVariables' singleton in scene 'IdahPrototype'.
  at Ludiq.SceneSingleton`1[Bolt.SceneVariables].FindOrCreateInstance (Scene scene) [0x000a5] in C:\Users\lazlo\Projects\Ludiq\Ludiq.Core\Runtime\Unity\SceneSingleton.cs:128 
  at Ludiq.SceneSingleton`1[Bolt.SceneVariables].InstanceIn (Scene scene) [0x0002d] in C:\Users\lazlo\Projects\Ludiq\Ludiq.Core\Runtime\Unity\SceneSingleton.cs:74 
  at Bolt.SceneVariables.Instance (Scene scene) [0x00000] in <filename unknown>:0 
  at Bolt.SceneVariables.For (Nullable`1 scene) [0x00000] in <filename unknown>:0 
  at Bolt.Variables.Scene (Nullable`1 scene) [0x00000] in <filename unknown>:0 
  at Bolt.EditorVariablesUtility.GetPredefinedVariableNames (VariableKind kind, Ludiq.GraphReference reference) [0x00067] in C:\Users\lazlo\Projects\Ludiq\Bolt.Core\Editor\Variables\EditorVariablesUtility.cs:86 
  at Bolt.EditorVariablesUtility.GetVariableNameSuggestions (VariableKind kind, Ludiq.GraphReference reference) [0x00000] in C:\Users\lazlo\Projects\Ludiq\Bolt.Core\Editor\Variables\EditorVariablesUtility.cs:111 
  at Bolt.UnitBase+<GetContextualOptions>d__15.MoveNext () [0x0006c] in C:\Users\lazlo\Projects\Ludiq\Bolt.Flow\Editor\Options\UnitBase.cs:598 
  at System.Collections.Generic.HashSet`1[Bolt.IUnitOption]..ctor (IEnumerable`1 collection, IEqualityComparer`1 comparer) [0x00000] in <filename unknown>:0 
  at System.Collections.Generic.HashSet`1[Bolt.IUnitOption]..ctor (IEnumerable`1 collection) [0x00000] in <filename unknown>:0 
  at Ludiq.LinqUtility.ToHashSet[IUnitOption] (IEnumerable`1 enumerable) [0x00000] in C:\Users\lazlo\Projects\Ludiq\Ludiq.Core\Runtime\Utilities\LinqUtility.cs:39 
  at Bolt.UnitBase+<>c__DisplayClass7_0.<Subset>b__1 () [0x00000] in C:\Users\lazlo\Projects\Ludiq\Bolt.Flow\Editor\Options\UnitBase.cs:370 
  at Ludiq.UnityAPI+<>c__DisplayClass10_0`1[System.Collections.Generic.HashSet`1[Bolt.IUnitOption]].<Await>b__0 () [0x00000] in C:\Users\lazlo\Projects\Ludiq\Ludiq.Core\Editor\Utilities\UnityAPI.cs:133 
UnityEngine.Debug:LogError(Object)
Bolt.UnitOptionTree:Prewarm() (at C:/Users/lazlo/Projects/Ludiq/Bolt.Flow/Editor/Options/UnitOptionTree.cs:48)
Ludiq.<>c__DisplayClass21_0:<Initialize>b__0() (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Editor/Interface/Fuzzy/FuzzyWindow.cs:274)
Ludiq.FuzzyWindow:Work() (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Editor/Interface/Fuzzy/FuzzyWindow.cs:1063)


And this one as well, but this error also appeared before the whole thing broke. To fix this I tried to disable automatic scene variable creation as told in the forum and it worked for a short period of time, now the error is back. Retry of the solution suggestion didn't work this time.


UnityException: More than one 'Bolt.SceneVariables' singleton in scene 'IdahPrototype'.
Ludiq.SceneSingleton`1[Bolt.SceneVariables].FindOrCreateInstance (Scene scene) (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Runtime/Unity/SceneSingleton.cs:128)
Ludiq.SceneSingleton`1[Bolt.SceneVariables].InstanceIn (Scene scene) (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Runtime/Unity/SceneSingleton.cs:74)
Bolt.SceneVariables.Instance (Scene scene)
Bolt.VariablesPanel.Scene () (at C:/Users/lazlo/Projects/Ludiq/Bolt.Core/Editor/Variables/VariablesPanel.cs:233)
Bolt.VariablesPanel..ctor (IGraphContext context) (at C:/Users/lazlo/Projects/Ludiq/Bolt.Core/Editor/Variables/VariablesPanel.cs:40)
Bolt.FlowGraphContext+<CreateSidebarPanels>d__3.MoveNext () (at C:/Users/lazlo/Projects/Ludiq/Bolt.Flow/Editor/FlowGraphContext.cs:16)
System.Collections.Generic.List`1[Ludiq.ISidebarPanelContent].AddEnumerable (IEnumerable`1 enumerable) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/List.cs:128)
System.Collections.Generic.List`1[Ludiq.ISidebarPanelContent]..ctor (IEnumerable`1 collection) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/List.cs:65)
System.Linq.Enumerable.ToArray[ISidebarPanelContent] (IEnumerable`1 source)
Ludiq.GraphContext`2[TGraph,TCanvas].get_sidebarPanels ()
Ludiq.GraphWindow.OnContextChange ()
Ludiq.GraphWindow.set_reference (Ludiq.GraphReference value)
Ludiq.GraphWindow.MatchSelection ()
Ludiq.GraphWindow.<OnEnable>b__54_0 ()
Ludiq.PluginContainer.add_delayCall (System.Action value) (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Editor/Plugins/PluginContainer.cs:38)
Ludiq.GraphWindow.OnEnable ()
UnityEditor.EditorWindow:GetWindow()
Ludiq.GraphWindow:OpenActive(GraphReference)
Ludiq.GraphNestEditor:OnEditButtonGUI(Rect)
Ludiq.GraphNestEditor:OnGUI(Rect, GUIContent)
Ludiq.Inspector:Draw(Rect, GUIContent) (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Editor/Inspection/Inspector.cs:93)
Ludiq.LudiqGUI:Editor(Metadata, Rect) (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Editor/Interface/LudiqGUI.cs:101)
Ludiq.MachineEditor:OnNestGUI(Rect)
Ludiq.MachineEditor:OnGUI(Rect, GUIContent)
Ludiq.Inspector:Draw(Rect, GUIContent) (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Editor/Inspection/Inspector.cs:93)
Ludiq.Inspector:DrawLayout(GUIContent, Single, RectOffset) (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Editor/Inspection/Inspector.cs:275)
Ludiq.Individual:OnGUI() (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Editor/Inspection/Root/LudiqRootObjectEditor.cs:52)
Ludiq.OptimizedEditor`1:OnInspectorGUI() (at C:/Users/lazlo/Projects/Ludiq/Ludiq.Core/Editor/Inspection/OptimizedEditor.cs:33)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)


And last but not least:


NullReferenceException: Object reference not set to an instance of an object
Ludiq.GraphClipboard.get_selection ()
Ludiq.GraphClipboard.get_canCopySelection ()
Ludiq.Canvas`1+<GetContextOptions>d__135[Bolt.FlowGraph].MoveNext ()
System.Linq.Enumerable.Any[DropdownOption] (IEnumerable`1 source)
Bolt.FlowCanvas.OnContext () (at C:/Users/lazlo/Projects/Ludiq/Bolt.Flow/Editor/FlowCanvas.cs:185)
Ludiq.Canvas`1[TGraph].HandleContext ()
Ludiq.Canvas`1[TGraph].HandleLowPriorityInput ()
Ludiq.Canvas`1[TGraph].OnGUI ()
Ludiq.GraphWindow.OnGUI ()
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:232)
System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MethodBase.cs:115)
UnityEditor.HostView.Invoke (System.String methodName, System.Object obj) (at C:/buildslave/unity/build/Editor/Mono/HostView.cs:295)
UnityEditor.HostView.Invoke (System.String methodName) (at C:/buildslave/unity/build/Editor/Mono/HostView.cs:288)
UnityEditor.HostView.InvokeOnGUI (Rect onGUIPosition) (at C:/buildslave/unity/build/Editor/Mono/HostView.cs:255)


I must admit, Bolt is one of the best assets I've bought and helped us so much. I hope there is a solution for this problem and we can continue to use Bolt. Time is our enemy right now and we need bolt for some major changes. Any help would be highly appreciated!


Thanks in advance & have a great day!

Bolt Version:
Unity Version:
Platform(s):
Scripting Backend:
.NET Version (API Compatibility Level):
GOOD, I'M SATISFIED
Satisfaction mark by Delta5.1 2 years ago
Pending Review

Hi Delta! Sorry you're having this issue.

Which version of Bolt are you using? Latest v.1.4.0f6? The scene singleton issue should have been fixed a while ago.

Apart from disabling the auto-scene-variables-creation, you probably want to go through your scene(s) and delete duplicate instances of scene variables. You can search for: t:scenevariables in the hierarchy search box to find them all instantly. There should be, at most, one per scene.

After you've done this, try restarting Unity, then rebuilding the unit options. Note any error or warning that happens there, and we'll try to move forward.

Hi Lazlo, thank you so much! I followed your instructions and now Bolt seems to work perfectly fine.

I'll try to work with Bolt today, if any error occurs I'll let you know but  I think it's fixed now. No errors or warnings so far.

Bolt version is v.1.4.0f6 btw.

Cannot Reproduce

Glad you got it resolved! I'll have to mark it as Cannot Reproduce though because the reproductions steps are unclear (you imported a lot of assets at once and it's not clear when or why it broke). If you ever run into the issue again, make sure to note what you did right before it occurred and try reproducing it on a new, small project.