-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Assertion failed in Spotlight.getIntersection() #156
Comments
@arouinfar should this be addressed for the prototype? I have not investigated whether it causes the sim to crash in practice. |
This issue is a duplicate of #177. In #177 (comment), @KatieWoe reported this CT failure:
In #177 (comment), @jbphet reported: I played around with this for a bit and was able to get it to happen manually a few times, but it's not easy. Below is a screenshot of one of these trials. To duplicate, set the sim's controls up as shown and move the pencil around a bunch. It took me about five or ten minutes and a lot of movement, and I didn't notice any particular pattern. When I looked at the stack trace, I noticed that there is a call to this.shapeProperty = new DerivedProperty( [
screenPositionProperty,
optic.positionProperty,
optic.diameterProperty,
targetPositionProperty ],
( screenPosition, opticPosition, opticDiameter, targetPosition ) => {
if ( screenPosition.x === 200 && screenPosition.y === 0 &&
opticPosition.x === 0 && opticPosition.y === 0 &&
targetPosition.x < -60 && targetPosition.x > -80 &&
targetPosition.y < 120 & targetPosition.y > 100
) {
targetPosition.x = -68.18783218424616;
targetPosition.y = 110.31233303003494;
}
return this.getIntersection( screenPosition, opticPosition, opticDiameter, targetPosition );
} ); With this code in place, if the user moves the pencil to the position shown in the image above, the problem will occur every time. @jonathanolson - The point where the assertion is thrown is several layers deep in some of the kite repo code, and is unfamiliar territory to me. The line of code is:
I dumped the value of |
This seems related to (duplicate of?) #163. But I'm hesitant to close, because there seems to be more than 1 problem that the sim is hitting in kite when Spotlight.getIntersection() is called. |
In #215 (comment) we decided not to address assertion failure issues for the prototype, so back to @pixelzoom. |
Since this is not in the prototype, unassigning until I start working on public production issues. |
This is probably the same as #163, since they both mention |
Has this been reproduced since phetsims/kite#90 was fixed? |
I've never been able to reproduce this. So I'll go ahead and close this, assuming that it's a duplicate of #163, and QA is testing that issue. |
I hit this assertion during my first time playing with the sim for #154. I don't feel like I did anything out of the ordinary, or even tried to break it. I pretty much just moved the lens a small amount, and then dragged around the pencil, eventually leading to the bottom left, as shown in the picture. Sorry I didn't have my dev tools open so that I could have paused in the stack trace to give more information. Note the "reentry detected" assertion is likely just downstream of the original problem, and you can probably ignore it.
The text was updated successfully, but these errors were encountered: