phetsims / fourier-making-waves

"Fourier: Making Waves" is an educational simulation in HTML5, by PhET Interactive Simulations.
GNU General Public License v3.0
6 stars 3 forks source link

CT: Cannot read properties of undefined (reading 'play') #243

Closed pixelzoom closed 8 months ago

pixelzoom commented 8 months ago

Occurring occassionally:

fourier-making-waves : fuzz : built
http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz
Query: fuzz
Uncaught TypeError: Cannot read properties of undefined (reading 'play')
TypeError: Cannot read properties of undefined (reading 'play')
at <unknown> (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:1483806)
at In.emit (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:24838)
at In.notifyListeners (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:26261)
at In.set (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:25996)
at In.set (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:472955)
at set value [as value] (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:25907)
at Tf.hideListBox (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:1490171)
at dismissWithFocusListener (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:1488840)
at r.emit (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:24838)
at r._notifyListeners (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:18687)
[URL] http://128.138.93.172/continuous-testing/aqua/html/sim-test.html?url=..%2F..%2Fct-snapshots%2F1704382578286%2Ffourier-making-waves%2Fbuild%2Fphet%2Ffourier-making-waves_en_phet.html&simQueryParameters=fuzz&duration=80000&testInfo=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D
[NAVIGATED] http://128.138.93.172/continuous-testing/aqua/html/sim-test.html?url=..%2F..%2Fct-snapshots%2F1704382578286%2Ffourier-making-waves%2Fbuild%2Fphet%2Ffourier-making-waves_en_phet.html&simQueryParameters=fuzz&duration=80000&testInfo=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D
[NAVIGATED] about:blank
[NAVIGATED] http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz
[CONSOLE] continuous-test-load
[PAGE ERROR] Error: TypeError: Cannot read properties of undefined (reading 'play')
at http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:1483806
at In.emit (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:24838)
at In.notifyListeners (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:26261)
at In.set (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:25996)
at In.set (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:472955)
at set value [as value] (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:25907)
at Tf.hideListBox (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:1490171)
at dismissWithFocusListener (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:1488840)
at r.emit (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:24838)
at r._notifyListeners (http://128.138.93.172/continuous-testing/ct-snapshots/1704382578286/fourier-making-waves/build/phet/fourier-making-waves_en_phet.html?continuousTest=%7B%22test%22%3A%5B%22fourier-making-waves%22%2C%22fuzz%22%2C%22built%22%5D%2C%22snapshotName%22%3A%22snapshot-1704382578286%22%2C%22timestamp%22%3A1704384323631%7D&fuzz:1012:18687)
[CONSOLE] continuous-test-error

id: "Sparky Node Puppeteer"
Snapshot from 1/4/2024, 8:36:18 AM
pixelzoom commented 8 months ago

Running locally, I hit this assertion in ComboBoxListBox:

const selectionIndex = this.getVisibleListItemNodes().indexOf( this.selectionOnFireAction );
assert && assert( selectionIndex !== -1, 'sound generation does not support adding new items' );

This is something that @jbphet and I added recently, while working on https://github.com/phetsims/sun/issues/861. I'm not sure how new items are possibly being added, will need to investigate. Perhaps there's a bug in ComboBoxListBox that assumes that all items are initially visible.

I'm also not sure whether this is the cause of the failure being reported by CT.

pixelzoom commented 8 months ago

This is a duplicate of #244. Here's the relevant code in ComboBoxListBox. #244 is failing the assertion. This issue is failing the next line because the test is "fuzz : built", and assertions are stripped out of built versions.

           // The selected item didn't provide a sound player, so use a default based on its position within the list
           // of visible selections.
           const selectionIndex = this.getVisibleListItemNodes().indexOf( this.selectionOnFireAction );
           assert && assert( selectionIndex !== -1, 'sound generation does not support adding new items' );
           defaultItemSelectedSoundPlayers[ selectionIndex ].play();