-
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: Not handling arcs with start/end angles that show differences in-between browser handling #261
Comments
The related code is // Make the arrow easier to grab by setting pointer areas
if ( rootVector.magnitude > 0 && this.arrowNode.shape ) {
this.arrowNode.mouseArea = this.arrowNode.shape.getOffsetShape( VectorAdditionConstants.VECTOR_MOUSE_AREA_DILATION );
this.arrowNode.touchArea = this.arrowNode.shape.getOffsetShape( VectorAdditionConstants.VECTOR_TOUCH_AREA_DILATION );
} Inspecting |
// Constraints that should always be satisfied
assert && assert( !( ( !this.anticlockwise && this._endAngle - this._startAngle <= -Math.PI * 2 ) ||
( this.anticlockwise && this._startAngle - this._endAngle <= -Math.PI * 2 ) ),
'Not handling arcs with start/end angles that show differences in-between browser handling' );
assert && assert( !( ( !this.anticlockwise && this._endAngle - this._startAngle > Math.PI * 2 ) ||
( this.anticlockwise && this._startAngle - this._endAngle > Math.PI * 2 ) ),
'Not handling arcs with start/end angles that show differences in-between browser handling' ); |
Noted in slack:
This looks like something I should handle, since it seems to be happening in a getOffsetShape call. |
The relevant code is noted above, RootVectorNode, where And thanks for handling! |
This is the last issue holding up the next RC, and we need to move on. So I've pushed a workaround in the commits above to master and 1.0 branches. This workaround is OK as a permanent solution, since other parts of the code use @jonathanolson if you want to investigate further, rollback the above changes in a branch. FYI, the assertion failure was occurring in the code shown in #261 (comment) when |
The general issue has been moved to phetsims/kite#82. It's not necessary to have @arouinfar or QA review, because this very obviously fails or doesn't fail with one specific set of conditions, which I've tested. So moving this issue to "fixed-awaiting-deploy", and it will be regressed in the next RC cycle. |
This no longer seems to cause an assertion failure in rc.2 |
Related to phetsims/qa#445 and phetsims/qa#446.
Discovered during investigation of #260.
This occurs on macOS 10.14.6 with Chrome 77 & 78, Safari 13.0.1, and Firefox 70 (and I suspect other supported platforms.)
It occurs in master bb1e85e and 1.0.0-rc.1/vector-addition_all_phet_debug.html?ea
Steps to reproduce:
?ea
This happens when 'd' and 'e' magnitude pickers are equal and 1, 2, or 3. It does not happen when they are 4-10, 0, or any negative value.
Chrome stack trace:
The text was updated successfully, but these errors were encountered: