valence icon indicating copy to clipboard operation
valence copied to clipboard

Extractor output is non-determinisic.

Open dyc3 opened this issue 1 year ago • 1 comments

Valence Version

6338fc630073bda6fdcb09e6acbb72ba87ea4a7c

What You Did

Run the extractor

What Went Wrong

Running the extractor does not produce exactly the same output every time. The overall structure will be the same, but fields and items in arrays may be in different orders.

This causes very messy diffs when Minecraft updates, or when a new extractor is added.

Additional Information

dyc3 avatar Jun 08 '23 11:06 dyc3

The problem is caused by an incorrect assumption. The extractor assumes that the default value for a particular tracked data field is the same across entity classes that inherit the field, but this is incorrect. The output format of the extractor will have to be changed along with the entity code generator in valence_entity.

Rather than having one system per tracked data, there needs to be one system per entity archetype.

rj00a avatar Jun 08 '23 11:06 rj00a