0
Cannot Reproduce
arvidsson 2 weeks ago • updated 4 days ago 14

Hi!

I thought it would be ok to set/get object variables in a macro, but I now understand it's not possible. However, after correcting my mistake I have to restart Unity in order to get Bolt working again. It would be good if it wasn't possible at all to add those units for macros.

I get these errors:


Cannot Reproduce

Hi arvidsson! Welcome to the community.

Sorry you're experiencing this issue.

I cannot reproduce it on my end.

Which version of Bolt are you using? 1.0.4?

What are the steps to reproduce this bug exactly?

Hi!

Yes, 1.0.4.

Steps to Reproduce:

1. Create Flow Macro

2. Add unit "Set Object Variable"

3. Get the following error in Unity:

Exception: Ludiq.InvalidImplementationException: The provided member is not supported on that unit type.
  at Bolt.MemberUnit.ReflectMember () [0x00052] in C:\Users\Lazlo\Projects\Ludiq\Bolt.Flow\Runtime\Flow\Framework\Codebase\MemberUnit.cs:107 
  at Bolt.MemberUnit.OnAfterDeserialize () [0x00000] in C:\Users\Lazlo\Projects\Ludiq\Bolt.Flow\Runtime\Flow\Framework\Codebase\MemberUnit.cs:64 
  at Ludiq.FullSerializer.fsSerializationCallbackReceiverProcessor.OnAfterDeserialize (System.Type storageType, System.Object instance) [0x00004] in C:\Users\Lazlo\Projects\Ludiq\Ludiq.Core\Runtime\Dependencies\FullSerializer\fsISerializationCallbacks.cs:126 
  at Ludiq.FullSerializer.fsSerializer.Invoke_OnAfterDeserialize (System.Collections.Generic.List`1 processors, System.Type storageType, System.Object instance) [0x0000b] in C:\Users\Lazlo\Projects\Ludiq\Ludiq.Core\Runtime\Dependencies\FullSerializer\fsSerializer.cs:1152 
  at Ludiq.FullSerializer.fsSerializer.TryDeserialize (Ludiq.FullSerializer.fsData data, System.Type storageType, System.Type overrideConverterType, System.Object& result) [0x00054] in C:\Users\Lazlo\Projects\Ludiq\Ludiq.Core\Runtime\Dependencies\FullSerializer\fsSerializer.cs:637 
Ludiq.FullSerializer.fsResult.AssertSuccess () (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Runtime/Dependencies/FullSerializer/fsResult.cs:166)
Ludiq.Serialization.HandleResult (System.String label, fsResult result, UnityEngine.Object context) (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Runtime/Serialization/Serialization.cs:162)
Ludiq.Serialization.DeserializeJson (Ludiq.FullSerializer.fsSerializer serializer, System.String json, System.Object& instance, Boolean forceReflected) (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Runtime/Serialization/Serialization.cs:157)
Ludiq.Serialization.DeserializeInto (SerializationData data, System.Object& instance, Boolean forceReflected) (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Runtime/Serialization/Serialization.cs:106)
Rethrow as SerializationException: Deserialization into 'null' failed.
Ludiq.Serialization.DeserializeInto (SerializationData data, System.Object& instance, Boolean forceReflected) (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Runtime/Serialization/Serialization.cs:111)
Ludiq.Serialization.Deserialize (SerializationData data, Boolean forceReflected) (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Runtime/Serialization/Serialization.cs:118)
Bolt.UnitOption`1[TUnit].get_unit () (at C:/Users/Lazlo/Projects/Ludiq/Bolt.Flow/Editor/Options/UnitOption.cs:61)
Bolt.UnitOption`1[TUnit].Bolt.IUnitOption.get_unit () (at C:/Users/Lazlo/Projects/Ludiq/Bolt.Flow/Editor/Options/UnitOption.cs:72)
Bolt.UnitOptionTree+<>c__DisplayClass42_0.<UnorderedSearchResults>b__1 (IUnitOption option) (at C:/Users/Lazlo/Projects/Ludiq/Bolt.Flow/Editor/Options/UnitOptionTree.cs:412)
System.Linq.Enumerable+<CreateWhereIterator>c__Iterator1D`1[Bolt.IUnitOption].MoveNext ()
System.Collections.Generic.List`1[Bolt.IUnitOption].AddEnumerable (IEnumerable`1 enumerable) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/List.cs:128)
System.Collections.Generic.List`1[Bolt.IUnitOption]..ctor (IEnumerable`1 collection) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/List.cs:65)
System.Linq.Enumerable.ToArray[IUnitOption] (IEnumerable`1 source)
Bolt.UnitBase+<WithoutDuplicateUnits>d__20`1[Bolt.IUnitOption].MoveNext () (at C:/Users/Lazlo/Projects/Ludiq/Bolt.Flow/Editor/Options/UnitBase.cs:407)
Bolt.UnitOptionTree+<UnorderedSearchResults>d__42.MoveNext () (at C:/Users/Lazlo/Projects/Ludiq/Bolt.Flow/Editor/Options/UnitOptionTree.cs:412)
System.Collections.Generic.List`1[Ludiq.IOrderableSearchResult].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.IOrderableSearchResult]..ctor (IEnumerable`1 collection) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/List.cs:65)
System.Linq.Enumerable.ToArray[IOrderableSearchResult] (IEnumerable`1 source)
System.Linq.QuickSort`1[Ludiq.IOrderableSearchResult]..ctor (IEnumerable`1 source, System.Linq.SortContext`1 context)
System.Linq.QuickSort`1+<Sort>c__Iterator21[Ludiq.IOrderableSearchResult].MoveNext ()
System.Linq.Enumerable+<CreateSelectIterator>c__Iterator10`2[Ludiq.IOrderableSearchResult,System.Object].MoveNext ()
Ludiq.ExtensibleFuzzyOptionTree+<SearchResults>d__9.MoveNext () (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Editor/Interface/Fuzzy/ExtensibleFuzzyOptionTree.cs:75)
System.Collections.Generic.List`1[System.Object].AddEnumerable (IEnumerable`1 enumerable) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/List.cs:128)
System.Collections.Generic.List`1[System.Object]..ctor (IEnumerable`1 collection) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/List.cs:65)
System.Linq.Enumerable.ToArray[Object] (IEnumerable`1 source)
Ludiq.FuzzyWindow.Populate (Ludiq.FuzzyOptionNode node, IEnumerable`1 childrenValues, Nullable`1 cancellation) (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Editor/Interface/Fuzzy/FuzzyWindow.cs:22)
Ludiq.FuzzyWindow+<>c__DisplayClass61_0.<Search>b__0 () (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Editor/Interface/Fuzzy/FuzzyWindow.cs:504)
Ludiq.FuzzyWindow.Work () (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Editor/Interface/Fuzzy/FuzzyWindow.cs:217)
UnityEngine.Debug:LogException(Exception)
Ludiq.FuzzyWindow:Work() (at C:/Users/Lazlo/Projects/Ludiq/Ludiq.Core/Editor/Interface/Fuzzy/FuzzyWindow.cs:222)

4. Remove the Unit

5. Try to add another unit, the fuzzy finder freezes or loads forever and out comes the Unity errors I mention above.

I do not get this error when adding a set object variable unit.

1) Can you regenerate your unit database then restart unity? (Tools > Bolt > Update Unit Options)

2) If the issue persists, can you send me a small project in which the issue occurs?

1) I tried it, didn't solve anything.

2) I tried making a new project with just Bolt, and then could not reproduce the issue.

3) I tried removing Bolt entirely in my current project, and then reinstalling it. And the issue is there again.

It also happened when adding a Get Graph Variable unit so now I'm getting worried :(

Under Review

Hi Arvidsson,

In this case, this is likely related to a third-party plugin you are using.

It's hard for me to track down unless I know which plugin is offending. I can add a better error log for the next version, but that means you'll have to wait until next version before I can even start debugging.

Can you try adding your third-party plugins to your new project 1 by 1, rebuilding the unit database in between each, and note when it starts failing?

I don't even need to add a unit in order to get the error, so something is breaking in the fuzzy finder. Can I exclude third-party plugins so their code isn't covered by the fuzzy finder and included in the unit database?

You can only exclude them if they are shipped as DLL's, not as scripts. "Excluding" them would mean not adding them the the assembly options in the first page of the unit options wizard.

Yes, the issue is related to the fuzzy finder, and more specifically to the unit options. It seems that a third party plugin you have is providing a member for reflection that is not of the right kind (e.g. constructor/property/field/method). I can't pin point it without your project however.

If you want to send your project in private, you can do so via this form on the front page:


+1

Resetting the assembly options seems to have fixed it. Sorry for the trouble. I guess this could be part of a Troubleshooting FAQ what to try first if there is any problems :)

That is actually a smart idea. One concise place of things to try if something presents as a bug but is not. 

I spoke prematurely. I still get errors in the fuzzy finder but I don't know a way to reproduce it.

I will try to add my other plugins to an empty project when I have time in a few days.

Hi arvidsson,

Can you please try again now that v.1.0.5 is out? 

You shouldn't get a fatal exception like before, and there should be a more specific warning message to pin point where it's coming from.

I will try to do it later today.

I upgraded and right now I don't get any errors or other issues. It seems to work alright, but I will test some more in my project and report here if I encounter anything strange.