phetsims / sun

User-interface components for PhET simulations, built on top of Scenery.
MIT License
4 stars 12 forks source link

CT: value failed isValidValue: 10.2 #745

Closed pixelzoom closed 2 years ago

pixelzoom commented 2 years ago

The first time I see this in CT history is 3/14/22 @ 11:42. Then it occurs occassionally.

fourier-making-waves : interactive-description-fuzzBoard : unbuilt
https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/fourier-making-waves/fourier-making-waves_en.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22interactive-description-fuzzBoard%22%2C%22unbuilt%22%5D%2C%22snapshotName%22%3A%22snapshot-1647424495960%22%2C%22timestamp%22%3A1647429040241%7D&brand=phet&ea&fuzzBoard&supportsInteractiveDescription=true&memoryLimit=1000
Query: brand=phet&ea&fuzzBoard&supportsInteractiveDescription=true&memoryLimit=1000
Uncaught Error: Assertion failed: value failed isValidValue: 10.2
Error: Assertion failed: value failed isValidValue: 10.2
at window.assertions.assertFunction (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/assert/js/assert.js:25:13)
at Object.isValueValid (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/ValidatorDef.js:299:39)
at validate (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/validate.js:33:18)
at NumberProperty.validateNumberAndRangeProperty (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/NumberProperty.js:103:43)
at NumberProperty.validateNumberProperty (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/NumberProperty.js:255:14)
at https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/NumberProperty.js:144:68
at TinyProperty.emit (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/TinyEmitter.js:68:9)
at NumberProperty._notifyListeners (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/Property.js:227:23)
at NumberProperty.set (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/Property.js:156:14)
at NumberSpinner.handleKeyDown (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/sun/js/accessibility/AccessibleValueHandler.js:418:33)
id: Bayes Chrome
Snapshot from 3/16/2022, 3:54:55 AM
pixelzoom commented 2 years ago

Hmm... I see similar failures in other sims, for example see below. They all involve NumberSpinner and AccessibleValueHandler, so I'm going to transfer this issue from fourier-making-waves to sun.

@jessegreenberg @zepumph are there any recent changes that might point to this problem?

gas-properties : phet-io-input-record-and-playback-fuzzBoard : unbuilt
https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/phet-io-wrappers/input-record-and-playback/?sim=gas-properties&phetioDebug&fuzzBoard&supportsInteractiveDescription=true&wrapperContinuousTest=%7B%22test%22%3A%5B%22gas-properties%22%2C%22phet-io-input-record-and-playback-fuzzBoard%22%2C%22unbuilt%22%5D%2C%22snapshotName%22%3A%22snapshot-1647424495960%22%2C%22timestamp%22%3A1647444051825%7D
Uncaught Error: Uncaught Error: Assertion failed: Property value not valid: value failed isValidValue: 25.2
Error: Assertion failed: Property value not valid: value failed isValidValue: 25.2
at window.assertions.assertFunction (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/assert/js/assert.js:25:13)
at Object.isValueValid (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/ValidatorDef.js:299:39)
at validate (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/validate.js:33:18)
at https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/Property.js:119:26
at TinyProperty.emit (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/TinyEmitter.js:68:9)
at NumberProperty._notifyListeners (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/Property.js:227:23)
at NumberProperty.set (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/axon/js/Property.js:156:14)
at GasPropertiesSpinner.handleKeyDown (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/sun/js/accessibility/AccessibleValueHandler.js:418:33)
at GasPropertiesSpinner._accessibleNumberSpinnerHandleKeyDown (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/sun/js/accessibility/AccessibleNumberSpinner.js:168:12)
at Object.keydown (https://bayes.colorado.edu/continuous-testing/ct-snapshots/1647424495960/chipper/dist/js/sun/js/accessibility/AccessibleNumberSpinner.js:100:24)
id: Bayes Chrome
Snapshot from 3/16/2022, 3:54:55 AM
jessegreenberg commented 2 years ago

This is happening if you press PgUp or PgDn on a NumberSpinner. I think this has been a problem with NumberSpinner for a long time but only recently started showing up because of more coverage in https://github.com/phetsims/scenery/issues/1379.

Fixed in the above commit by enforcing the step size used by NumberSpinner for pageKeyboardStep as we do for the others. I verified that no sims hit the assertion I added for this. @zepumph would you mind reviewing?

zepumph commented 2 years ago

Wow! An actual bug caught by fuzzBoard! This is great news. Thanks for taking care of it. Commit looks great.