Closed Bug 599568 Opened 9 years ago Closed 9 years ago

physicSketch Experiment fails to retain drawn objects


(Core :: JavaScript Engine, defect)

Not set



Tracking Status
blocking2.0 --- betaN+


(Reporter: andrewcondinho, Unassigned)




(Whiteboard: [chromeexperiments])

User-Agent:       Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.0b7pre) Gecko/20100924 Firefox/4.0b7pre
Build Identifier: Build identifier: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.0b7pre) Gecko/20100924 Firefox/4.0b7pre

Basically, once you launch the experiment, whenever you attempt to draw any shapes on the canvas it shows the lines and then they disappear. After about the 3rd attempt it stops even drawing the lines at all. 

This issue does not occur in Chrome, or Firefox 3.6, and I also tested it on 32/64-bit machines.

Reproducible: Always

Steps to Reproduce:
1. Launch experiment.
2. Draw a shape in the canvas.
3. Objects fail to appear.
Actual Results:  
The lines that you draw are visible while drawing, however when you let go of the mouse button to complete the shame they disappear. After 3 tries it stops even drawing the preliminary lines. 

Expected Results:  
The shapes you draw should stay retained and drop according to the programmed physics.
Whiteboard: [chromeexperiments]
Summary: Experiment fails to retain drawn objects → physicSketch Experiment fails to retain drawn objects
It's throwing on this line:

    context.moveTo(point.x, point.y);

which means one of those is a NaN or Infinity.

Can you narrow down when this problem first appeared?  Doing that using tracemonkey nightlies might be a good idea...  What's needed is the http:// URL from about:buildconfig for the nightlies immediately before and after the problem appears.
This one uses box2d.js too, just like the Google Gravity one -- bug 595541
Ever confirmed: true
I haven't used tracemonkey before how would I go about doing this?
Though given comment 2, starting with m-c nightlies might be better (and in fact just starting with the bug 595541 range and seeing whether it applies here).
Depends on: 595541
I checked the m-c nightlies at those bugs ranges and for

Mozilla Central
2010-08-31-04-mozilla-central - Experiment works
2010-09-01-04-mozilla-central - Experiment works
2010-09-01-09-mozilla-central - Experiment works

So not sure if they are related, I'll start at the latest release and go back until I find the builds where it breaks.
Ok I've narrowed it down to these 2 m-c builds

Mozilla Central
2010-09-11-04-mozilla-central - Experiment works
2010-09-12-04-mozilla-central - Experiment doesn't work

I then tested the tracemonkey builds and had to go back another day to find one that worked

2010-09-10-04-tracemonkey - Experiment works
2010-09-11-04-tracemonkey - Experiment doesn't work
ok.  For those tracemonkey builds, what are the changeset ids?  See comment 1.
I'm hoping these are the ids you're looking for...

2010-09-10-04-tracemonkey -
2010-09-11-04-tracemonkey -
Yes, perfect.

Regression range:

Which happens to include a mozilla-central merge, and not that many other things.  You're very sure about the moilla-central regression range in comment 7, right?  _That_ range has the tracemonkey merge that landed jaegermonkey in it...
Assignee: nobody → general
blocking2.0: --- → ?
Component: Canvas: 2D → JavaScript Engine
QA Contact: canvas.2d → general
(In reply to comment #10)
> _That_ range has the tracemonkey merge that landed jaegermonkey in it...

I can confirm that this is jaegermonkey-related: if I go to about:config and set javascript.options.methodjit.content to false (which means disable jaegermonkey), that fixes the problem.
This eventually gives:

Error: uncaught exception: [Exception... "An invalid or illegal string was specified"  code: "12" nsresult: "0x8053000c (NS_ERROR_DOM_SYNTAX_ERR)"  location: " Line: 335"]

Error: (void 0) is undefined
Source File:
Line: 292

and stops working.  The first one is triggered by itself if you draw a shape that doesn't have endpoints connected; after that you can't draw any more.  The second is triggered if you try to draw an illegal shape, or if something happens inside box2d that causes its processing to abort (e.g. I've had the physics animation just die on me in the middle of an object falling).
> Error: (void 0) is undefined
> Source File:
> Line: 292

That's the same thing happening in bug 595541
May also be related to bug 597378. The pinball demo also uses box2d...
Thanks, Jan, I've verified this to be fixed by the same dependency as bug 597378.
Closed: 9 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 597378
blocking2.0: ? → betaN+
You need to log in before you can comment on or make changes to this bug.