-
Notifications
You must be signed in to change notification settings - Fork 40
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
Random asset load order in Safari causing runtime bugs #13
Comments
Dr Nic, thanks for pointing this out. It looks like we need to explicitly chain the requires in the blue-ridge.js file rather than just require them all asynchronously. |
Hi, I reordered the require's in blue-ridge.js like so:
Everything loads in order, but it tests still don't run correctly on Safari 4. Any ideas? |
Let's just take a moment to observe how disturbing that code looks due to the nested nature. ... I need another moment... :D If we do get this working, it would be fun to come up with a DSL for nested require's, something like: require('some_file.js'). then_require('dependent_file.js) That would be sweet. Are you coming to FutureRuby this weekend? |
@tanzeeb: Have you actually got it working with that? When I make that change, the files load correctly, but Safari 4.0.2 doesn't actually run any of the tests. It looks like Safari either 1) isn't telling jQuery that the DOM is ready or 2) telling jQuery that the DOM is ready too soon. |
@karnowski - @tanzeeb says above it still isn't working for him on Safari. Hmm, interesting problem. I'm sure I've seen the tests run occasionally on Safari. Hopefully I can find some time to poke around. Stupid bug. |
Ah, so he does! Thanks @drnic. |
@drnic Well if you rotate your monitor 90 degrees, it looks like a very nice pyramid. ;-) Missed out on FutureRuby, did you go? How was it? @karnowski No I still haven't figured out why it doesn't run in Safari 4. Tight deadline on my project, but once its done I'll take a look to see why. I think you're right about it being a jQuery / DOM Ready issue. |
any updates? I'm stuck with a safari specific bug and I'd love to write some tests to verify the bugs are fixed. |
Updates: We can use tazeeb's fix above, but then we're still stuck with the Safari-4 problem described in issue #21. I'm leaving this issue open to add tanzeeb's fix (but with a more fluent interface on require). |
I/we are nearly there with a fix to this. See my "safari" branch for current code. It's not ready yet, but close. A few things of note: This has broken existing tests, so I'll have to sort that out. |
See my pull request. |
I'm running tests in multiple browsers using ndp's branch. I think this is a great improvement and fixes two open issues. |
In Safari 4.0.1, the generated <script> tags are correct, but Safari is loading the various assets in non-deterministic order; that is, random. So in running tests sometimes they don't run at all because jQuery or screw.builder hasn't been loaded yet.
Uploaded with plasq's Skitch!
Uploaded with plasq's Skitch!
The text was updated successfully, but these errors were encountered: