{"action":"closed","issue":{"url":"https://api.github.com/repos/phetsims/function-builder/issues/18","repository_url":"https://api.github.com/repos/phetsims/function-builder","labels_url":"https://api.github.com/repos/phetsims/function-builder/issues/18/labels{/name}","comments_url":"https://api.github.com/repos/phetsims/function-builder/issues/18/comments","events_url":"https://api.github.com/repos/phetsims/function-builder/issues/18/events","html_url":"https://github.com/phetsims/function-builder/issues/18","id":141720083,"number":18,"title":"assertion failures in CardNode.startDrag and endDrag","user":{"login":"pixelzoom","id":3046552,"avatar_url":"https://avatars.githubusercontent.com/u/3046552?v=3","gravatar_id":"","url":"https://api.github.com/users/pixelzoom","html_url":"https://github.com/pixelzoom","followers_url":"https://api.github.com/users/pixelzoom/followers","following_url":"https://api.github.com/users/pixelzoom/following{/other_user}","gists_url":"https://api.github.com/users/pixelzoom/gists{/gist_id}","starred_url":"https://api.github.com/users/pixelzoom/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pixelzoom/subscriptions","organizations_url":"https://api.github.com/users/pixelzoom/orgs","repos_url":"https://api.github.com/users/pixelzoom/repos","events_url":"https://api.github.com/users/pixelzoom/events{/privacy}","received_events_url":"https://api.github.com/users/pixelzoom/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/phetsims/function-builder/labels/type:bug","name":"type:bug","color":"FF00AA"}],"state":"closed","locked":false,"assignee":{"login":"pixelzoom","id":3046552,"avatar_url":"https://avatars.githubusercontent.com/u/3046552?v=3","gravatar_id":"","url":"https://api.github.com/users/pixelzoom","html_url":"https://github.com/pixelzoom","followers_url":"https://api.github.com/users/pixelzoom/followers","following_url":"https://api.github.com/users/pixelzoom/following{/other_user}","gists_url":"https://api.github.com/users/pixelzoom/gists{/gist_id}","starred_url":"https://api.github.com/users/pixelzoom/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pixelzoom/subscriptions","organizations_url":"https://api.github.com/users/pixelzoom/orgs","repos_url":"https://api.github.com/users/pixelzoom/repos","events_url":"https://api.github.com/users/pixelzoom/events{/privacy}","received_events_url":"https://api.github.com/users/pixelzoom/received_events","type":"User","site_admin":false},"milestone":null,"comments":1,"created_at":"2016-03-17T22:11:52Z","updated_at":"2016-03-17T22:20:24Z","closed_at":"2016-03-17T22:20:24Z","body":"Factored out of https://github.com/phetsims/function-builder/issues/16#issuecomment-198048645 and https://github.com/phetsims/function-builder/issues/16#issuecomment-198049175, automated testing (Chrome) report by @phet-steele on 3/17/16.  \r\n\r\nThese 2 issues come in pairs and are likely related.\r\n\r\nThis error occurs in CardNode.startDrag, when we see that the node is in the animationLayer, where it should not be pickable:\r\n\r\n```\r\nassert.js:23 Uncaught Error: Assertion failed: nodes in animationLayer should not be pickable\r\nwindow.assertions.assertFunction @ assert.js:23\r\nCardNode.options.startDrag @ CardNode.js?bust=1458242805484:71\r\nMovableNode.addInputListener.SimpleDragHandler.start @ MovableNode.js?bust=1458242805484:56\r\ninherit.startDrag @ SimpleDragHandler.js?bust=1458242805484:153\r\ninherit.tryToSnag @ SimpleDragHandler.js?bust=1458242805484:180\r\ninherit.down @ SimpleDragHandler.js?bust=1458242805484:197\r\ninherit.dispatchToTargets @ Input.js?bust=1458242805484:846\r\ninherit.dispatchEvent @ Input.js?bust=1458242805484:788\r\ninherit.downEvent @ Input.js?bust=1458242805484:672\r\ninherit.mouseDown @ Input.js?bust=1458242805484:315\r\nextend.fuzzMouseEvents @ Display.js?bust=1458242805484:1095\r\ninherit.stepSimulation @ Sim.js?bust=1458242805484:683\r\ninherit.runAnimationLoop @ Sim.js?bust=1458242805484:657\r\n```\r\n\r\nThis error occurs in CardNode.endDrag, where the node should be in dragLayer:\r\n\r\n```\r\nassert.js:23 Uncaught Error: Assertion failed: Attempted to removeChild with a node that was not a child.\r\nwindow.assertions.assertFunction @ assert.js:23\r\nextend.removeChild @ Node.js?bust=1458242805484:382\r\nCardNode.options.endDrag @ CardNode.js?bust=1458242805484:140\r\nMovableNode.addInputListener.SimpleDragHandler.end @ MovableNode.js?bust=1458242805484:68\r\ninherit.endDrag @ SimpleDragHandler.js?bust=1458242805484:165\r\nSimpleDragHandler.dragListener.up @ SimpleDragHandler.js?bust=1458242805484:74\r\ninherit.dispatchToPointer @ Input.js?bust=1458242805484:811\r\ninherit.dispatchEvent @ Input.js?bust=1458242805484:784\r\ninherit.upEvent @ Input.js?bust=1458242805484:654\r\ninherit.mouseUp @ Input.js?bust=1458242805484:326\r\nextend.fuzzMouseEvents @ Display.js?bust=1458242805484:1091\r\ninherit.stepSimulation @ Sim.js?bust=1458242805484:683\r\ninherit.runAnimationLoop @ Sim.js?bust=1458242805484:657\r\n```\r\n"}}