#509·theatre

sheet.detachObject doesn't clear staticOverrides

Author: akre54Created Aug 11, 2025Updated Nov 18, 2025

If I create an object with sheet.object('obj', { num: types.number(0) }), set the value of num to 20 in the UI, and then later call sheet.detachObject('num'), I'd expect that the exported state would be empty. Instead I have a key in staticOverrides for the prop.

I can verify this by calling sheet.object again with the same config, and the UI shows its value as 20. My expectation would be that the number should reset to the default 0 value, and that I wouldn't get an exported prop.

It looks like the internal Sheet class only deletes the object from this._objects and not any of the dataverse pointers.

Is this an easy fix?