phetsims / build-a-molecule

"Build a Molecule" is an educational simulation in HTML5, by PhET Interactive Simulations.
GNU General Public License v3.0
8 stars 7 forks source link

CT error: Uncaught TypeError: Cannot read properties of undefined (reading 'addParticleNearestOpen') #236

Open samreid opened 1 year ago

samreid commented 1 year ago

Probably caused by https://github.com/phetsims/sun/issues/814. After dynamic Carousel was merged to master, this error started appearing on CT.

build-a-molecule : fuzz : unbuilt
https://bayes.colorado.edu/continuous-testing/ct-snapshots/1675487724863/build-a-molecule/build-a-molecule_en.html?continuousTest=%7B%22test%22%3A%5B%22build-a-molecule%22%2C%22fuzz%22%2C%22unbuilt%22%5D%2C%22snapshotName%22%3A%22snapshot-1675487724863%22%2C%22timestamp%22%3A1675506949161%7D&brand=phet&ea&fuzz&memoryLimit=1000
Query: brand=phet&ea&fuzz&memoryLimit=1000
Uncaught TypeError: Cannot read properties of undefined (reading 'addParticleNearestOpen')
TypeError: Cannot read properties of undefined (reading 'addParticleNearestOpen')
at addParticleNearestOpen (Kit.js:424:11)
at recycleAtomIntoBuckets (Kit.js:438:11)
at Array.forEach
at forEach (Kit.js:437:19)
at recycleMoleculeIntoBuckets (Kit.js:214:11)
at atomDropped (BAMScreenView.js:437:19)
at _end (DragListener.ts:381:24)
at callback (PressListener.ts:750:16)
at apply (PhetioAction.ts:157:16)
at execute (PressListener.ts:508:24)
id: Bayes Puppeteer
Snapshot from 2/3/2023, 10:15:24 PM

I can reproduce the problem but cannot figure out what caused it or how to resolve it. Perhaps @jonathanolson would be the best candidate to address it, since he has knowledge of both this sim and of the Carousel changes.

jonathanolson commented 1 year ago

Lots of other things also seem a bit messed up with this sim in master. I'll sometime want to take a look, and really convert things to Typescript to flush out all of the CT issues that are happening.