phetsims / buoyancy

"Buoyancy" is an educational simulation in HTML5, by PhET Interactive Simulations.
GNU General Public License v3.0
2 stars 2 forks source link

Turn on PhET-iO Validation #114

Closed zepumph closed 1 week ago

zepumph commented 2 months ago

Discovered when we were surprised that we didn't get an assertion from a duplicate phetioID over in https://github.com/phetsims/buoyancy/issues/31

samreid commented 1 week ago

@zepumph would you take a look and see if there is more to do in this issue?

zepumph commented 1 week ago

Mostly good but I have a few questions:

I didn't get through everything.

samreid commented 1 week ago

Should there be a blank object in package.jsons for phet-io? I don't think so.

I don't think so either

This line is commented out in Mass.ts: // phetioDynamicElement: true

Good catch, that was a crutch that got me pointed toward https://github.com/phetsims/density-buoyancy-common/blob/f5586050caec5b7b83b96ee3e2b400161f34ff0f/js/buoyancy/model/BuoyancyShapesModel.ts#L99-L105 and it can be removed.

I think we should try to make the density, buoyancy and buoyancy-basics package.jsons look as similar as possible. Right now they have deviations, even different lint rules.

zepumph commented 1 week ago

Ok great. I made some good changes to the packages for consistency. Mostly getting lint consistent. I also threw in testing designed changes for all three in phet-io. Seems just as good to do it for all sims.

zepumph commented 1 week ago

Ready to close?