SetProperty with null value issue prevents property from being reassigned and saved correctly

Found the issue with the property system. When using the following line:

node.SetProperty("Homer", null);

The property can no longer be reassigned. When saved into fbx and loaded again, the property has a null value despite being reassigned.

After the above null set, the following lines have no effect on the output file:

node.SetProperty("Homer", "Smart");

or

var property = node.FindProperty( "Homer" );
property.Value = "Smart";

Ive attached an .sln with a unit test. Please see the PropertyValueNotBeingUpdated.cs file. Other file is from a previous bug report, please ignore.

PropertyIssue.zip (3.3 KB)

See test case:

[ Test ]
        [ TestCaseSource( nameof(FormatsSupportingNodeProperties) ) ]
        public void Set_property_value_with_value_property_saves_and_loads_correctly( FileFormat format )
        {
            Scene scene = new Scene();
            Node node = scene.RootNode.CreateChildNode( "Child" );

            // Set property to null for later assignment
            node.SetProperty("Homer", null);

            var property = node.FindProperty( "Homer" );
            Assert.NotNull( property );

            node.SetProperty("Homer", "Smart");

            Assert.AreEqual( "Smart", node.GetProperty( "Homer" ) );

            var outScene = SaveAndOpenNewInstance( scene, format );
            var outNode = outScene.RootNode.ChildNodes.Single();

            Assert.NotNull( outNode.FindProperty( "Homer" ) );
            Assert.AreEqual( "Smart", outNode.GetProperty( "Homer" ) );
        }

@bortos,

Thanks for contacting support.

We have tested this scenario in our environment and have been able to observe the issue that you have mentioned. We have logged issue with ID THREEDNET-633 in our issue tracking system. We will share with you as soon as logged issue is fixed.

The issues you have found earlier (filed as THREEDNET-633) have been fixed in this update.

The issues you have found earlier (filed as THREEDNET-633) have been fixed in this update.