phetsims / natural-selection

"Natural Selection" is an educational simulation in HTML5, by PhET Interactive Simulations
GNU General Public License v3.0
3 stars 7 forks source link

CT Designed API changes detected, please roll them back or revise the reference API: #338

Closed KatieWoe closed 1 year ago

KatieWoe commented 1 year ago
natural-selection : phet-io-api-compatibility : unbuilt
https://sparky.colorado.edu/continuous-testing/ct-snapshots/1688154842092/natural-selection/natural-selection_en.html?continuousTest=%7B%22test%22%3A%5B%22natural-selection%22%2C%22phet-io-api-compatibility%22%2C%22unbuilt%22%5D%2C%22snapshotName%22%3A%22snapshot-1688154842092%22%2C%22timestamp%22%3A1688157243224%7D&ea&brand=phet-io&phetioStandalone&phetioCompareAPI&randomSeed=332211&locales=*
Query: ea&brand=phet-io&phetioStandalone&phetioCompareAPI&randomSeed=332211&locales=*
Error: Assertion failed: Designed API changes detected, please roll them back or revise the reference API:

naturalSelection.introScreen.model.bunnyCollection.bunnyGroup.archetype._data.initialState differs.
Expected:
{"_cumulativeHopTime":0,"_cumulativeRestTime":0,"_hopDelta":{"x":-15.327782972534292,"y":34.62373754230146,"z":-10.727941820566173},"_hopStartPosition":{"x":55.76894907888192,"y":-38.02092448170239,"z":242.96861327744642},"_hopTime":0.309426659541408,"_restTime":2.1005642973791527,"age":0,"father":null,"generation":0,"isAlive":true,"mother":null}
actual:
{"father":null,"mother":null,"generation":0,"isAlive":true,"age":0,"_restTime":2.1005642973791527,"_hopTime":0.309426659541408,"_cumulativeRestTime":0,"_cumulativeHopTime":0,"_hopDelta":{"x":-15.327782972534294,"y":34.62373754230146,"z":-10.727941820566173},"_hopStartPosition":{"x":55.76894907888192,"y":-38.02092448170239,"z":242.96861327744642}}

@https://sparky.colorado.edu/continuous-testing/ct-snapshots/1688154842092/assert/js/assert.js:28:22
at <unknown> (https://sparky.colorado.edu/continuous-testing/ct-snapshots/1688154842092/assert/js/assert.js:28:22)
at results (phetioEngine.ts:371:30)
[URL] https://sparky.colorado.edu/continuous-testing/aqua/html/sim-test.html?url=..%2F..%2Fct-snapshots%2F1688154842092%2Fnatural-selection%2Fnatural-selection_en.html&simQueryParameters=ea%26brand%3Dphet-io%26phetioStandalone%26phetioCompareAPI%26randomSeed%3D332211%26locales%3D*&testInfo=%7B%22test%22%3A%5B%22natural-selection%22%2C%22phet-io-api-compatibility%22%2C%22unbuilt%22%5D%2C%22snapshotName%22%3A%22snapshot-1688154842092%22%2C%22timestamp%22%3A1688157243224%7D
[NAVIGATED] https://sparky.colorado.edu/continuous-testing/aqua/html/sim-test.html?url=..%2F..%2Fct-snapshots%2F1688154842092%2Fnatural-selection%2Fnatural-selection_en.html&simQueryParameters=ea%26brand%3Dphet-io%26phetioStandalone%26phetioCompareAPI%26randomSeed%3D332211%26locales%3D*&testInfo=%7B%22test%22%3A%5B%22natural-selection%22%2C%22phet-io-api-compatibility%22%2C%22unbuilt%22%5D%2C%22snapshotName%22%3A%22snapshot-1688154842092%22%2C%22timestamp%22%3A1688157243224%7D
[NAVIGATED] about:blank
[NAVIGATED] https://sparky.colorado.edu/continuous-testing/ct-snapshots/1688154842092/natural-selection/natural-selection_en.html?continuousTest=%7B%22test%22%3A%5B%22natural-selection%22%2C%22phet-io-api-compatibility%22%2C%22unbuilt%22%5D%2C%22snapshotName%22%3A%22snapshot-1688154842092%22%2C%22timestamp%22%3A1688157243224%7D&ea&brand=phet-io&phetioStandalone&phetioCompareAPI&randomSeed=332211&locales=*
[CONSOLE] enabling assert
[CONSOLE] Assertion failed: Designed API changes detected, please roll them back or revise the reference API:

naturalSelection.introScreen.model.bunnyCollection.bunnyGroup.archetype._data.initialState differs.
Expected:
{"_cumulativeHopTime":0,"_cumulativeRestTime":0,"_hopDelta":{"x":-15.327782972534292,"y":34.62373754230146,"z":-10.727941820566173},"_hopStartPosition":{"x":55.76894907888192,"y":-38.02092448170239,"z":242.96861327744642},"_hopTime":0.309426659541408,"_restTime":2.1005642973791527,"age":0,"father":null,"generation":0,"isAlive":true,"mother":null}
actual:
{"father":null,"mother":null,"generation":0,"isAlive":true,"age":0,"_restTime":2.1005642973791527,"_hopTime":0.309426659541408,"_cumulativeRestTime":0,"_cumulativeHopTime":0,"_hopDelta":{"x":-15.327782972534294,"y":34.62373754230146,"z":-10.727941820566173},"_hopStartPosition":{"x":55.76894907888192,"y":-38.02092448170239,"z":242.96861327744642}}

[PAGE ERROR] Error: Assertion failed: Designed API changes detected, please roll them back or revise the reference API:

naturalSelection.introScreen.model.bunnyCollection.bunnyGroup.archetype._data.initialState differs.
Expected:
{"_cumulativeHopTime":0,"_cumulativeRestTime":0,"_hopDelta":{"x":-15.327782972534292,"y":34.62373754230146,"z":-10.727941820566173},"_hopStartPosition":{"x":55.76894907888192,"y":-38.02092448170239,"z":242.96861327744642},"_hopTime":0.309426659541408,"_restTime":2.1005642973791527,"age":0,"father":null,"generation":0,"isAlive":true,"mother":null}
actual:
{"father":null,"mother":null,"generation":0,"isAlive":true,"age":0,"_restTime":2.1005642973791527,"_hopTime":0.309426659541408,"_cumulativeRestTime":0,"_cumulativeHopTime":0,"_hopDelta":{"x":-15.327782972534294,"y":34.62373754230146,"z":-10.727941820566173},"_hopStartPosition":{"x":55.76894907888192,"y":-38.02092448170239,"z":242.96861327744642}}

[CONSOLE] continuous-test-load
[CONSOLE] continuous-test-error

id: "Safari from Node"
Snapshot from 6/30/2023, 1:54:02 PM
pixelzoom commented 1 year ago

Looks like someone changed something and didn't test migration rules. @samreid @zepumph is this related to your changes for "private" fields in schemas?

zepumph commented 1 year ago

It seems to be because some state is about position, and we started testing ct on some safari devices which yield very small differences based on fuzz input. I'll take a look.

zepumph commented 1 year ago

Specifically the only difference in the bunny states above is _hopDelta.x:

'x': -15.327782972534294 'x': -15.327782972534292

All else is the same.

zepumph commented 1 year ago

This should be fixed generally by https://github.com/phetsims/phet-io/issues/1951.

pixelzoom commented 1 year ago

This is still occurring on CT, most recently on 7/8/2023, 8:41:00 AM.

pixelzoom commented 1 year ago

Natural Selection is now scheduled for this iteration, and I need to complete this by 8/3.

pixelzoom commented 1 year ago

Unassigning myself because I can't do anything until https://github.com/phetsims/phet-io/issues/1951 is addressed.

pixelzoom commented 1 year ago

Decision from PhET-iO Meeting in https://github.com/phetsims/phet-io/issues/1951#issuecomment-1654233408 is that this is not blocking for Natural Selection, and this issue can be closed.

zepumph commented 7 months ago

BTW, this issue likely stopped showing up on CT because safari testing stopped at some point over the summer. But now this is fixed generally over in https://github.com/phetsims/aqua/issues/200.