Opened 14 years ago

Closed 12 years ago

#208 closed defect (fixed)

debugAtAllCosts: dojo.provides race conditions

Reported by: bill@… Owned by: James Burke
Priority: high Milestone: 1.0
Component: General Version: 0.1
Keywords: Cc:
Blocked By: Blocking:


In browser_debug.js, dojo.hostenv.loadUri calls dojo.provide(), thus creating an empty package, but the package isn't filled in (with functions definitions, etc.) until much later in writeIncludes().

In particular this leads to a problem in event.js, which does a "if(dojo.eventbrowser?)". The code inside the "if" is executed because dojo.event.browser exists, but breaks because dojo.event.browser doesn't contain the expected functions.

Try loading test_fisheyewidget.html while moving your mouse over the screen (near where the icons are displayed) and then look in the javascript console to see the problem.

Change History (6)

comment:1 Changed 13 years ago by Tom Trenka

Bill, is this still an issue?

comment:2 Changed 13 years ago by bill

Summary: debug mode handling of dojo.provides leads to race conditionsdebugAtAllCosts: dojo.provides race conditions

Yeah. If you change debugAtAllCosts to true in test_fisheyeWidget.html and then move your mouse during page load there will be dozens of errors. (On the other hand, there are sometimes errors even when debugAtAllCosts is false)

comment:3 Changed 13 years ago by dylan

Milestone: 0.6

comment:4 Changed 13 years ago by dylan

Owner: changed from anonymous to alex

comment:5 Changed 12 years ago by James Burke

Owner: changed from alex to James Burke

This should be fixed in 1.0, since debugAtAllCosts does not depend on writeIncludes() now and uses the xdomain loading mechanism.

comment:6 Changed 12 years ago by James Burke

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.