Custom modernizr builds crash IE8 #332

Closed
thasmo opened this Issue Aug 2, 2011 · 64 comments

Comments

Projects
None yet
@thasmo

thasmo commented Aug 2, 2011

We have experienced that custom, compressed modernizr builds crash IE8,
resulting in showing this address in the addressbar:
res://ieframe.dll/acr_error.html/#

This is not happening in the compat modes of IE7 or IE8 in IE9.

Unfortunately we can't really test this any further as we don't have
a machine with IE8 installed. The machine we experienced this on,
was a Windows XP machine of one of our partner companies.

Using the uncompressed development version does work without errors:
http://www.modernizr.com/downloads/modernizr-2.0.6.js

@dottodot

This comment has been minimized.

Show comment
Hide comment
@dottodot

dottodot Aug 4, 2011

I have the same problem, if I use the uncompressed version I do not have this issue.

I have ie8 to test on but not sure how to find whats causing the problem.

dottodot commented Aug 4, 2011

I have the same problem, if I use the uncompressed version I do not have this issue.

I have ie8 to test on but not sure how to find whats causing the problem.

@gordonbrander

This comment has been minimized.

Show comment
Hide comment
@gordonbrander

gordonbrander Aug 4, 2011

Having the same issue with the following build in IE 8.0.6.001.18702/XP:

/* Modernizr 2.0.6 (Custom Build) | MIT & BSD
 * Contains: iepp | respond | mq | cssclasses | teststyles
 */

I have not yet tested with other builds.

Having the same issue with the following build in IE 8.0.6.001.18702/XP:

/* Modernizr 2.0.6 (Custom Build) | MIT & BSD
 * Contains: iepp | respond | mq | cssclasses | teststyles
 */

I have not yet tested with other builds.

@gordonbrander

This comment has been minimized.

Show comment
Hide comment
@gordonbrander

gordonbrander Aug 4, 2011

Update: also tested it with a full build using the generator:

/* Modernizr 2.0.6 (Custom Build) | MIT & BSD
 * Contains: fontface | backgroundsize | borderimage | borderradius | boxshadow | flexbox | hsla | multiplebgs | opacity | rgba | textshadow | cssanimations | csscolumns | generatedcontent | cssgradients | cssreflections | csstransforms | csstransforms3d | csstransitions | applicationcache | canvas | canvastext | draganddrop | hashchange | history | audio | video | indexeddb | input | inputtypes | localstorage | postmessage | sessionstorage | websockets | websqldatabase | webworkers | geolocation | inlinesvg | smil | svg | svgclippaths | touch | webgl | iepp | respond | mq | cssclasses | addtest | prefixed | teststyles | testprop | testallprops | hasevent | prefixes | domprefixes | load
 */

Update: this is almost certainly related: scottjehl/Respond#27.

I removed Modernizr from my page in order to test, and added HTML5 Shiv + Respond.js instead. WIth respond.js, the page throws this error in IE 8.0.6.001.18702/XP. Without, it's fine.

Update 2: The issue definitely seems to be related to respond.js for me. Built the following:

/* Modernizr 2.0.6 (Custom Build) | MIT & BSD
 * Contains: iepp | cssclasses | load
 */

...and it runs no problem in IE8/XP. Adding respond.js to the build throws the error.

Update: also tested it with a full build using the generator:

/* Modernizr 2.0.6 (Custom Build) | MIT & BSD
 * Contains: fontface | backgroundsize | borderimage | borderradius | boxshadow | flexbox | hsla | multiplebgs | opacity | rgba | textshadow | cssanimations | csscolumns | generatedcontent | cssgradients | cssreflections | csstransforms | csstransforms3d | csstransitions | applicationcache | canvas | canvastext | draganddrop | hashchange | history | audio | video | indexeddb | input | inputtypes | localstorage | postmessage | sessionstorage | websockets | websqldatabase | webworkers | geolocation | inlinesvg | smil | svg | svgclippaths | touch | webgl | iepp | respond | mq | cssclasses | addtest | prefixed | teststyles | testprop | testallprops | hasevent | prefixes | domprefixes | load
 */

Update: this is almost certainly related: scottjehl/Respond#27.

I removed Modernizr from my page in order to test, and added HTML5 Shiv + Respond.js instead. WIth respond.js, the page throws this error in IE 8.0.6.001.18702/XP. Without, it's fine.

Update 2: The issue definitely seems to be related to respond.js for me. Built the following:

/* Modernizr 2.0.6 (Custom Build) | MIT & BSD
 * Contains: iepp | cssclasses | load
 */

...and it runs no problem in IE8/XP. Adding respond.js to the build throws the error.

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Aug 12, 2011

Member

hmmmmm @scottjehl we got a problem it seems.

Member

paulirish commented Aug 12, 2011

hmmmmm @scottjehl we got a problem it seems.

@thasmo

This comment has been minimized.

Show comment
Hide comment
@thasmo

thasmo Aug 19, 2011

Any progress on this? Wondering where I can get a Win XP version for testing this. :|

thasmo commented Aug 19, 2011

Any progress on this? Wondering where I can get a Win XP version for testing this. :|

@thasmo thasmo closed this Aug 19, 2011

@thasmo thasmo reopened this Aug 19, 2011

@thasmo

This comment has been minimized.

Show comment
Hide comment
@thasmo

thasmo Aug 19, 2011

Oops. oO The GUI mocked me. oO

thasmo commented Aug 19, 2011

Oops. oO The GUI mocked me. oO

@plockc

This comment has been minimized.

Show comment
Hide comment
@plockc

plockc Sep 15, 2011

There is a comment with 8 bit bytes near the method

tests['csstransforms3d']

that has what I'm guessing is a Microsoft "smart-quote"

We experience crashes of IE8 when we do not set a charset when serving this file (like running under lighttpd)

our fix: remove the comment

plockc commented Sep 15, 2011

There is a comment with 8 bit bytes near the method

tests['csstransforms3d']

that has what I'm guessing is a Microsoft "smart-quote"

We experience crashes of IE8 when we do not set a charset when serving this file (like running under lighttpd)

our fix: remove the comment

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Sep 15, 2011

Member

@plockc you've built this version recently? can you give us the top of the file which has what tests are in the build?

Member

paulirish commented Sep 15, 2011

@plockc you've built this version recently? can you give us the top of the file which has what tests are in the build?

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Sep 15, 2011

Member

remove what comment?

Member

paulirish commented Sep 15, 2011

remove what comment?

@plockc

This comment has been minimized.

Show comment
Hide comment
@plockc

plockc Sep 16, 2011

(sorry for all the edits, trying to figure out the code delimiters)

I didn't see what looked like a list of tests (sorry, I'm helping the markup guys, I don't use the library myself), but here is the version:

/*!
 * Modernizr v2.0.6
 * http://www.modernizr.com
 *
 * Copyright (c) 2009-2011 Faruk Ates, Paul Irish, Alex Sexton
 * Dual-licensed under the BSD or MIT licenses: www.modernizr.com/license/
 */

Asking the markup guy that got it, it should be a full build, pulled from here:
http://www.modernizr.com/downloads/modernizr-2.0.6.js

which I verify to have the same 8 bit bytes

The comment is here:

    tests['csstransforms3d'] = function() {

        var ret = !!testProps(['perspectiveProperty', 'WebkitPerspective', 'MozPerspective', 'OPerspective', 'msPerspective']);

        // Webkit<89>۪s 3D transforms are passed off to the browser's own graphics renderer.
        //   It works fine in Safari on Leopard and Snow Leopard, but not in Chrome in
        //   some conditions. As a result, Webkit typically recognizes the syntax but
        //   will sometimes throw a false positive, thus we must do a more thorough check:
        if ( ret && 'webkitPerspective' in docElement.style ) {

          // Webkit allows this media query to succeed only if the feature is enabled.
          // `@media (transform-3d),(-o-transform-3d),(-moz-transform-3d),(-ms-transform-3d),(-webkit-transform-3d),(modernizr){ ... }`
          ret = Modernizr['csstransforms3d'];
        }
        return ret;
    };

the first line of the comment should have been "WebKit's" I assume

Here is a test I use (found a high byte in jQuery 1.6.4.min with it as well):

hexdump -v -e '1/1 "%02X" "\n"' modernizr.js   | awk '/^[8-9A-F]/ {print NR " " $0} /[0-7]?/ {}'

Checking the latest from github, someone appears to be editing source code with a "smart quotes" editor and saving the file in UTF-8 (I think), there are many high byte sequences, for example hex E2 80 99 is a right single quote:

curl -o modernizr.js https://github.com/Modernizr/Modernizr/blob/master/modernizr.js

hexdump -v -e '1/1 "%02X" "\n"' modernizr.js   | awk '/^[8-9A-F]/ {print NR " " $0} /[0-7]?/ {}'

(each line of output is a decimal offset and the byte value in hex)
14516 E2
14517 86
14518 91

14557 E2
14558 86
14559 93

15842 E2
15843 80
15844 A6

171271 E2
171272 80
171273 99

286370 E2
286371 86
286372 90

286520 E2
286521 86
286522 92

286671 E2
286672 86
286673 91

286819 E2
286820 86
286821 93

287169 E2
287170 86
287171 90

287343 E2
287344 86
287345 92

287518 E2
287519 86
287520 91

287690 E2
287691 86
287692 93

plockc commented Sep 16, 2011

(sorry for all the edits, trying to figure out the code delimiters)

I didn't see what looked like a list of tests (sorry, I'm helping the markup guys, I don't use the library myself), but here is the version:

/*!
 * Modernizr v2.0.6
 * http://www.modernizr.com
 *
 * Copyright (c) 2009-2011 Faruk Ates, Paul Irish, Alex Sexton
 * Dual-licensed under the BSD or MIT licenses: www.modernizr.com/license/
 */

Asking the markup guy that got it, it should be a full build, pulled from here:
http://www.modernizr.com/downloads/modernizr-2.0.6.js

which I verify to have the same 8 bit bytes

The comment is here:

    tests['csstransforms3d'] = function() {

        var ret = !!testProps(['perspectiveProperty', 'WebkitPerspective', 'MozPerspective', 'OPerspective', 'msPerspective']);

        // Webkit<89>۪s 3D transforms are passed off to the browser's own graphics renderer.
        //   It works fine in Safari on Leopard and Snow Leopard, but not in Chrome in
        //   some conditions. As a result, Webkit typically recognizes the syntax but
        //   will sometimes throw a false positive, thus we must do a more thorough check:
        if ( ret && 'webkitPerspective' in docElement.style ) {

          // Webkit allows this media query to succeed only if the feature is enabled.
          // `@media (transform-3d),(-o-transform-3d),(-moz-transform-3d),(-ms-transform-3d),(-webkit-transform-3d),(modernizr){ ... }`
          ret = Modernizr['csstransforms3d'];
        }
        return ret;
    };

the first line of the comment should have been "WebKit's" I assume

Here is a test I use (found a high byte in jQuery 1.6.4.min with it as well):

hexdump -v -e '1/1 "%02X" "\n"' modernizr.js   | awk '/^[8-9A-F]/ {print NR " " $0} /[0-7]?/ {}'

Checking the latest from github, someone appears to be editing source code with a "smart quotes" editor and saving the file in UTF-8 (I think), there are many high byte sequences, for example hex E2 80 99 is a right single quote:

curl -o modernizr.js https://github.com/Modernizr/Modernizr/blob/master/modernizr.js

hexdump -v -e '1/1 "%02X" "\n"' modernizr.js   | awk '/^[8-9A-F]/ {print NR " " $0} /[0-7]?/ {}'

(each line of output is a decimal offset and the byte value in hex)
14516 E2
14517 86
14518 91

14557 E2
14558 86
14559 93

15842 E2
15843 80
15844 A6

171271 E2
171272 80
171273 99

286370 E2
286371 86
286372 90

286520 E2
286521 86
286522 92

286671 E2
286672 86
286673 91

286819 E2
286820 86
286821 93

287169 E2
287170 86
287171 90

287343 E2
287344 86
287345 92

287518 E2
287519 86
287520 91

287690 E2
287691 86
287692 93

@paulirish paulirish closed this in ee030ad Sep 16, 2011

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Sep 16, 2011

Member

thank you so much for the detail @plockc

Member

paulirish commented Sep 16, 2011

thank you so much for the detail @plockc

@lode

This comment has been minimized.

Show comment
Hide comment
@lode

lode Oct 28, 2011

I'am also having the issue of a 'crashing' IE8. The tab crashes and show indeed res://ieframe.dll/acr_error.html/#domain.ext,http://www.domain.ext/.

I'am using the minified version (from the html5 boilerplate) and can't find the comment in my modernizr source which is changed in the previous commit. Is this really all needed to fix this issue? To me it seems this won't help.

lode commented Oct 28, 2011

I'am also having the issue of a 'crashing' IE8. The tab crashes and show indeed res://ieframe.dll/acr_error.html/#domain.ext,http://www.domain.ext/.

I'am using the minified version (from the html5 boilerplate) and can't find the comment in my modernizr source which is changed in the previous commit. Is this really all needed to fix this issue? To me it seems this won't help.

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Oct 28, 2011

Member

@lode i would also get a minified version that does not include respond.js

Member

paulirish commented Oct 28, 2011

@lode i would also get a minified version that does not include respond.js

@lode

This comment has been minimized.

Show comment
Hide comment
@lode

lode Oct 29, 2011

@paulirish but it seems to me that I do need respond.js.

(Right now I've been able to "solve" it by using the development version of modernizr and minify it myself via jscompress.com. This one doesn't crash.)

lode commented Oct 29, 2011

@paulirish but it seems to me that I do need respond.js.

(Right now I've been able to "solve" it by using the development version of modernizr and minify it myself via jscompress.com. This one doesn't crash.)

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Oct 29, 2011

Member

you dont need respond.js.. you can do mobile-first MQs and get IE support with a conditional comments and two css files.

interesting bug though. :o

Member

paulirish commented Oct 29, 2011

you dont need respond.js.. you can do mobile-first MQs and get IE support with a conditional comments and two css files.

interesting bug though. :o

@thasmo

This comment has been minimized.

Show comment
Hide comment
@thasmo

thasmo Dec 6, 2011

Does this bug depend on shipping modernizr 2.1? Will it be fixed? Thanks guys!

thasmo commented Dec 6, 2011

Does this bug depend on shipping modernizr 2.1? Will it be fixed? Thanks guys!

@whereisaaron

This comment has been minimized.

Show comment
Hide comment
@whereisaaron

whereisaaron Jan 31, 2012

One data point for sufferers; We found that the attribute that triggered the IE crashes when combined with Modernizr was related to 'print' vs 'screen' style sheets 'media' attribute. We found that is you explicitly say 'screen' (which as you know is the default anyway) that leads to the IE crash. Here is the versions offending line:

  1. <link rel="stylesheet" href="/css/style.css"> --> No crash
  2. <link rel="stylesheet" href="/css/style.css" media="print"> --> No crash
  3. <link rel="stylesheet" href="/css/style.css" media="screen"> --> Crash!

We found if we avoid (3) we could avoid the IE crashes.

We have not used @import but with do use @media, e.g. '@media only screen and (min-width: 480px)'
CSS files that do not use @import or @media do not trigger the problem, even if you do explicitly specify 'media="screen"'.

Aaron.

One data point for sufferers; We found that the attribute that triggered the IE crashes when combined with Modernizr was related to 'print' vs 'screen' style sheets 'media' attribute. We found that is you explicitly say 'screen' (which as you know is the default anyway) that leads to the IE crash. Here is the versions offending line:

  1. <link rel="stylesheet" href="/css/style.css"> --> No crash
  2. <link rel="stylesheet" href="/css/style.css" media="print"> --> No crash
  3. <link rel="stylesheet" href="/css/style.css" media="screen"> --> Crash!

We found if we avoid (3) we could avoid the IE crashes.

We have not used @import but with do use @media, e.g. '@media only screen and (min-width: 480px)'
CSS files that do not use @import or @media do not trigger the problem, even if you do explicitly specify 'media="screen"'.

Aaron.

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Jan 31, 2012

Member

aaron fwiw this is a respond.js bug.

Member

paulirish commented Jan 31, 2012

aaron fwiw this is a respond.js bug.

@scottjehl

This comment has been minimized.

Show comment
Hide comment
@scottjehl

scottjehl Jan 31, 2012

Contributor

and a fixed one at that! :)

(but if you run into issues with it, please take the discussion over here: https://github.com/scottjehl/Respond/issues/ )

On Jan 31, 2012, at 9:27 AM, Paul Irish wrote:

aaron fwiw this is a respond.js bug.


Reply to this email directly or view it on GitHub:
#332 (comment)

Contributor

scottjehl commented Jan 31, 2012

and a fixed one at that! :)

(but if you run into issues with it, please take the discussion over here: https://github.com/scottjehl/Respond/issues/ )

On Jan 31, 2012, at 9:27 AM, Paul Irish wrote:

aaron fwiw this is a respond.js bug.


Reply to this email directly or view it on GitHub:
#332 (comment)

@whereisaaron

This comment has been minimized.

Show comment
Hide comment
@whereisaaron

whereisaaron Jan 31, 2012

Excellent Scott, glad this problem is fixed, but this problem was reported with 2.0.6 and I believe there hasn't been a release of Modernizr since the fix. So people using the current release version from http://www.modernizr.com/ (still 2.0.6 as of today) are still as far as I know getting the old version of Media Queries portion with this problem?
[ Of course since IE7/IE8 crash and burn the really problem it with IE and of course will probably never be fixed :-( ]

Excellent Scott, glad this problem is fixed, but this problem was reported with 2.0.6 and I believe there hasn't been a release of Modernizr since the fix. So people using the current release version from http://www.modernizr.com/ (still 2.0.6 as of today) are still as far as I know getting the old version of Media Queries portion with this problem?
[ Of course since IE7/IE8 crash and burn the really problem it with IE and of course will probably never be fixed :-( ]

@scottjehl

This comment has been minimized.

Show comment
Hide comment
@scottjehl

scottjehl Jan 31, 2012

Contributor

I'm fairly certain the Modernizr team has pulled Respond.js out of their builder, so you'll have to include it manually from the Respond.js repo. You should find that this problem no longer exists

I'm not sure exactly what the "media queries" checkbox does in there currently. Paul?

On Feb 1, 2012, at 2:09 AM, whereisaaron wrote:

Excellent Scott, glad this problem is fixed, but this problem was reported with 2.0.6 and I believe there hasn't been a release of Modernizr since the fix. So people using the current release version from http://www.modernizr.com/ (still 2.0.6 as of today) are still as far as I know getting the old version of Media Queries portion with this problem?
[ Of course since IE7/IE8 crash and burn the really problem it with IE and of course will probably never be fixed :-( ]


Reply to this email directly or view it on GitHub:
#332 (comment)

Contributor

scottjehl commented Jan 31, 2012

I'm fairly certain the Modernizr team has pulled Respond.js out of their builder, so you'll have to include it manually from the Respond.js repo. You should find that this problem no longer exists

I'm not sure exactly what the "media queries" checkbox does in there currently. Paul?

On Feb 1, 2012, at 2:09 AM, whereisaaron wrote:

Excellent Scott, glad this problem is fixed, but this problem was reported with 2.0.6 and I believe there hasn't been a release of Modernizr since the fix. So people using the current release version from http://www.modernizr.com/ (still 2.0.6 as of today) are still as far as I know getting the old version of Media Queries portion with this problem?
[ Of course since IE7/IE8 crash and burn the really problem it with IE and of course will probably never be fixed :-( ]


Reply to this email directly or view it on GitHub:
#332 (comment)

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Feb 1, 2012

Member

i thinkkkkkkkk it adds a

Modernizr.mediaqueries = Modernizr.mq('only all'); to your file. I think.

Member

paulirish commented Feb 1, 2012

i thinkkkkkkkk it adds a

Modernizr.mediaqueries = Modernizr.mq('only all'); to your file. I think.

@scottjehl

This comment has been minimized.

Show comment
Hide comment
@scottjehl

scottjehl Feb 1, 2012

Contributor

Oh okay - it's a support test. Right on. Thanks, Paul.

On Feb 1, 2012, at 7:30 AM, Paul Irish wrote:

i thinkkkkkkkk it adds a

Modernizr.mediaqueries = Modernizr.mq('only all'); to your file. I think.


Reply to this email directly or view it on GitHub:
#332 (comment)

Contributor

scottjehl commented Feb 1, 2012

Oh okay - it's a support test. Right on. Thanks, Paul.

On Feb 1, 2012, at 7:30 AM, Paul Irish wrote:

i thinkkkkkkkk it adds a

Modernizr.mediaqueries = Modernizr.mq('only all'); to your file. I think.


Reply to this email directly or view it on GitHub:
#332 (comment)

@donaldjenkins

This comment has been minimized.

Show comment
Hide comment
@donaldjenkins

donaldjenkins Feb 8, 2012

I'm getting the crash in IE 6/7/8 with a Modernizr 2.5.2 custom build (was not getting it with Modernizr 2.0.6).

I'm getting the crash in IE 6/7/8 with a Modernizr 2.5.2 custom build (was not getting it with Modernizr 2.0.6).

@scottjehl

This comment has been minimized.

Show comment
Hide comment
@scottjehl

scottjehl Feb 8, 2012

Contributor

Respond.js is no longer included in Modernizr's builder, so I'm not sure of the problem you're encountering here.

If it's a respond.js bug, please file it in the tracker over at https://github.com/scottjehl/Respond/issues

Thanks!

On Feb 8, 2012, at 11:07 PM, Donald Jenkins wrote:

I'm getting the crash in IE 6/7/8 with a Modernizr 2.5.2 custom build (was not getting it with Modernizr 2.0.6).


Reply to this email directly or view it on GitHub:
#332 (comment)

Contributor

scottjehl commented Feb 8, 2012

Respond.js is no longer included in Modernizr's builder, so I'm not sure of the problem you're encountering here.

If it's a respond.js bug, please file it in the tracker over at https://github.com/scottjehl/Respond/issues

Thanks!

On Feb 8, 2012, at 11:07 PM, Donald Jenkins wrote:

I'm getting the crash in IE 6/7/8 with a Modernizr 2.5.2 custom build (was not getting it with Modernizr 2.0.6).


Reply to this email directly or view it on GitHub:
#332 (comment)

@SherriAlexander

This comment has been minimized.

Show comment
Hide comment
@SherriAlexander

SherriAlexander Feb 9, 2012

I echo astorg's comment; just upgraded a site I've been working on to modernizr 2.5.2, and started getting hard crashes in IE 8. Went back to 2.0.6 and no crashes. I don't think respond.js is involved, as my custom build did not include it.

Here is the custom build I was using in case it helps track down the problem:

Modernizr 2.5.2 (Custom Build) | MIT & BSD
Build: http://www.modernizr.com/download/#-fontface-generatedcontent-input-inputtypes-shiv-cssclasses-teststyles-load

I echo astorg's comment; just upgraded a site I've been working on to modernizr 2.5.2, and started getting hard crashes in IE 8. Went back to 2.0.6 and no crashes. I don't think respond.js is involved, as my custom build did not include it.

Here is the custom build I was using in case it helps track down the problem:

Modernizr 2.5.2 (Custom Build) | MIT & BSD
Build: http://www.modernizr.com/download/#-fontface-generatedcontent-input-inputtypes-shiv-cssclasses-teststyles-load

@donaldjenkins

This comment has been minimized.

Show comment
Hide comment
@donaldjenkins

donaldjenkins Feb 9, 2012

Oh, so I'm not alone. Yup—it can't be respond.js as it's no longer included. So surely wouldn't make sense to file a bug in the respond.js issues tracker. My build, in case that helps, is:

http://www.modernizr.com/download/#-borderradius-boxshadow-opacity-video-inputtypes-shiv-cssclasses-testprop-testallprops-prefixes-domprefixes-load

Oh, so I'm not alone. Yup—it can't be respond.js as it's no longer included. So surely wouldn't make sense to file a bug in the respond.js issues tracker. My build, in case that helps, is:

http://www.modernizr.com/download/#-borderradius-boxshadow-opacity-video-inputtypes-shiv-cssclasses-testprop-testallprops-prefixes-domprefixes-load

@KuraFire

This comment has been minimized.

Show comment
Hide comment
@KuraFire

KuraFire Feb 9, 2012

Member

Are any of the people who are seeing crashes since 2.5.2 using Typekit? If so, see #308 for a potential fix. cc @AstorG @SherriAlexander

Member

KuraFire commented Feb 9, 2012

Are any of the people who are seeing crashes since 2.5.2 using Typekit? If so, see #308 for a potential fix. cc @AstorG @SherriAlexander

@SherriAlexander

This comment has been minimized.

Show comment
Hide comment
@SherriAlexander

SherriAlexander Feb 9, 2012

I'm using some custom fonts via @font-face, but not using Typekit on this project.

I'm using some custom fonts via @font-face, but not using Typekit on this project.

@scottjehl

This comment has been minimized.

Show comment
Hide comment
@scottjehl

scottjehl Feb 9, 2012

Contributor

Not sure if Modernizr is injecting any CSS into style elements like I do in Respond.js but if so, many of the IE instability issues in Respond were resolved by appending style elements to the DOM before populating them with styles. Before, I had all style elements populated and appended at once via document fragment, which I thought would've been faster, but caused other problems, like crashing if the HTML element had a background image. It also helped smooth out a @font-face issue in IE.

If that's all irrelevant here, just disregard, but I figured I'd mention it.

On Feb 9, 2012, at 9:48 AM, Sherri Alexander wrote:

I'm using some custom fonts via @font-face, but not using Typekit on this project.


Reply to this email directly or view it on GitHub:
#332 (comment)

Contributor

scottjehl commented Feb 9, 2012

Not sure if Modernizr is injecting any CSS into style elements like I do in Respond.js but if so, many of the IE instability issues in Respond were resolved by appending style elements to the DOM before populating them with styles. Before, I had all style elements populated and appended at once via document fragment, which I thought would've been faster, but caused other problems, like crashing if the HTML element had a background image. It also helped smooth out a @font-face issue in IE.

If that's all irrelevant here, just disregard, but I figured I'd mention it.

On Feb 9, 2012, at 9:48 AM, Sherri Alexander wrote:

I'm using some custom fonts via @font-face, but not using Typekit on this project.


Reply to this email directly or view it on GitHub:
#332 (comment)

@donaldjenkins

This comment has been minimized.

Show comment
Hide comment
@donaldjenkins

donaldjenkins Feb 9, 2012

I'm using Typekit so that's the likely reason (though, again, no issues with 2.0.6). What fix are you suggesting: calling Typekit before Modernizr, using html5.shivMethods = false;, or using:

test: Modernizr.fontface, yep: 'http://use.typekit.com/ypq0ypv.js', callback: function () { html5.shivMethods = false; // IE6 and 7 crash without this line try { Typekit.load(); } catch(e){} }

Using test: Modernizr.fontfacewould require adding in a scenario for browsers that don't support @fontface: seems overkill if one of the otrher solutions works.

I'm using Typekit so that's the likely reason (though, again, no issues with 2.0.6). What fix are you suggesting: calling Typekit before Modernizr, using html5.shivMethods = false;, or using:

test: Modernizr.fontface, yep: 'http://use.typekit.com/ypq0ypv.js', callback: function () { html5.shivMethods = false; // IE6 and 7 crash without this line try { Typekit.load(); } catch(e){} }

Using test: Modernizr.fontfacewould require adding in a scenario for browsers that don't support @fontface: seems overkill if one of the otrher solutions works.

@KuraFire

This comment has been minimized.

Show comment
Hide comment
@KuraFire

KuraFire Feb 9, 2012

Member

@AstorG The issue is that html5.shivMethods does the "innerShiv" functionality a little bit too aggressively for oldIE as of the new html5shiv 3.x (I think 3.x, anyway). Typekit uses that functionality but when something is already attached to the DOM and you change it, oldIE goes kaput.

The specific Modernizr.load / yepnope setup that I'm using is irrelevant here. You just need to set html5.shivMethods to false before the Typekit.load(); call to fix it, however you have your setup. Keep in mind that this is very much a temporary workaround !

Member

KuraFire commented Feb 9, 2012

@AstorG The issue is that html5.shivMethods does the "innerShiv" functionality a little bit too aggressively for oldIE as of the new html5shiv 3.x (I think 3.x, anyway). Typekit uses that functionality but when something is already attached to the DOM and you change it, oldIE goes kaput.

The specific Modernizr.load / yepnope setup that I'm using is irrelevant here. You just need to set html5.shivMethods to false before the Typekit.load(); call to fix it, however you have your setup. Keep in mind that this is very much a temporary workaround !

@donaldjenkins

This comment has been minimized.

Show comment
Hide comment
@donaldjenkins

donaldjenkins Feb 9, 2012

@KuraFire: Gotcha! I'll try that. Alternatively, I might just stick with 2.0.6, pending a more permanent fix. The main benefit of 2.5, for me, is speed (it does load faster in non-IE browsers). When you say temporary, what time frame are you talking about?

@KuraFire: Gotcha! I'll try that. Alternatively, I might just stick with 2.0.6, pending a more permanent fix. The main benefit of 2.5, for me, is speed (it does load faster in non-IE browsers). When you say temporary, what time frame are you talking about?

@KuraFire

This comment has been minimized.

Show comment
Hide comment
@KuraFire

KuraFire Feb 9, 2012

Member

@AstorG Alex, Alexander et al are pretty on top of it, it seems. I can't speak for them or make any guarantees, but at the rate of fixes of late, I'd say only a matter of days.

Member

KuraFire commented Feb 9, 2012

@AstorG Alex, Alexander et al are pretty on top of it, it seems. I can't speak for them or make any guarantees, but at the rate of fixes of late, I'd say only a matter of days.

@donaldjenkins

This comment has been minimized.

Show comment
Hide comment
@donaldjenkins

donaldjenkins Feb 9, 2012

@KuraFire Cool, I think I'll hold off pending a more permanent fix. Thanks for the prompt response!

@KuraFire Cool, I think I'll hold off pending a more permanent fix. Thanks for the prompt response!

@SherriAlexander

This comment has been minimized.

Show comment
Hide comment
@SherriAlexander

SherriAlexander Feb 9, 2012

I will try to do some more debugging and narrow it down to a culprit in my case, but I have to tame my raging project deadlines first. :)

I will try to do some more debugging and narrow it down to a culprit in my case, but I have to tame my raging project deadlines first. :)

@ryanve

This comment has been minimized.

Show comment
Hide comment
@ryanve

ryanve Feb 9, 2012

Contributor

I got the IE8 acr error when I upgraded the Modernizr build to 2.5.2 on two sites. Here's a screenshot. On responsejs.com it hit the error as soon the page opened. On virtualmusic.tv it hit the error after clicking a link. No Typekit in either case, and no respond.js when I tested it. I tried several different builds and I think it's isolated to the something in the new shiv. I have a computer that can test this if needed.
modernizr.com/download/#-shiv-cssclasses causes acr error
modernizr.com/download/#-cssclasses-load works fine

Contributor

ryanve commented Feb 9, 2012

I got the IE8 acr error when I upgraded the Modernizr build to 2.5.2 on two sites. Here's a screenshot. On responsejs.com it hit the error as soon the page opened. On virtualmusic.tv it hit the error after clicking a link. No Typekit in either case, and no respond.js when I tested it. I tried several different builds and I think it's isolated to the something in the new shiv. I have a computer that can test this if needed.
modernizr.com/download/#-shiv-cssclasses causes acr error
modernizr.com/download/#-cssclasses-load works fine

@zdennis

This comment has been minimized.

Show comment
Hide comment
@zdennis

zdennis Feb 10, 2012

We are experiencing this with shiv's alone in 2.5.2: http://www.modernizr.com/download/#-shiv

zdennis commented Feb 10, 2012

We are experiencing this with shiv's alone in 2.5.2: http://www.modernizr.com/download/#-shiv

@zdennis

This comment has been minimized.

Show comment
Hide comment
@zdennis

zdennis Feb 10, 2012

If I don't include html5shiv but I include most other things the problem doesn't happen. Separately adding in http://code.google.com/p/html5shiv/ seems to keep everything happy.

zdennis commented Feb 10, 2012

If I don't include html5shiv but I include most other things the problem doesn't happen. Separately adding in http://code.google.com/p/html5shiv/ seems to keep everything happy.

@zdennis

This comment has been minimized.

Show comment
Hide comment
@zdennis

zdennis Feb 10, 2012

To update, this issue happened on IE8 on Windows XP in Vmware Fusion. A colleague loaded in in IE8 on Windows 7 in Parallels and didn't experience any issues.

zdennis commented Feb 10, 2012

To update, this issue happened on IE8 on Windows XP in Vmware Fusion. A colleague loaded in in IE8 on Windows 7 in Parallels and didn't experience any issues.

@SherriAlexander

This comment has been minimized.

Show comment
Hide comment
@SherriAlexander

SherriAlexander Feb 10, 2012

In case it's OS-related, my issue also occurs in IE8 on Windows XP in
Parallels.

To update, this issue happened on IE8 on Windows XP in Vmware Fusion. A colleague loaded in in IE8 on Windows 7 in Parallels and didn't experience any issues.


Reply to this email directly or view it on GitHub:
#332 (comment)

Sherri Alexander
Front-End Web Developer
sherri@sherri-alexander.com
http://www.sherri-alexander.com

In case it's OS-related, my issue also occurs in IE8 on Windows XP in
Parallels.

To update, this issue happened on IE8 on Windows XP in Vmware Fusion. A colleague loaded in in IE8 on Windows 7 in Parallels and didn't experience any issues.


Reply to this email directly or view it on GitHub:
#332 (comment)

Sherri Alexander
Front-End Web Developer
sherri@sherri-alexander.com
http://www.sherri-alexander.com

@agross

This comment has been minimized.

Show comment
Hide comment
@agross

agross Feb 13, 2012

I see the issue with IE 8 on Windows Server 2003 R2 SP2 (base OS is similar to XP) as well.

Using the Modernizer 2.5.2 build without customizations (just html5shiv, load and the CSS classes without prefix). I don't use respond.js.

I've created a little reproduction over here: agross/modernizr-bug-332@cad5b14

agross commented Feb 13, 2012

I see the issue with IE 8 on Windows Server 2003 R2 SP2 (base OS is similar to XP) as well.

Using the Modernizer 2.5.2 build without customizations (just html5shiv, load and the CSS classes without prefix). I don't use respond.js.

I've created a little reproduction over here: agross/modernizr-bug-332@cad5b14

@Krinkle

This comment has been minimized.

Show comment
Hide comment
@Krinkle

Krinkle Feb 13, 2012

The custom Modernizer 2.5.2 build that ships with the latest version of the HTML5 Boilerplate is also causing complete browser shutdown crashes in IE8 on XP for me.

Please for this as soon as possible, reverting to 2.0.6 now.

After re-trying a couple of times, sometimes the browser doesn't crash but instead tries to re-load it a couple of times after failed attempts and eventually ends up at a url like res://ieframe.dll/acr_error.htm# *(domain, url). Also during the reloads it's showing a tooltip in the IE8 tab saying "This tab has been recovered".

Krinkle commented Feb 13, 2012

The custom Modernizer 2.5.2 build that ships with the latest version of the HTML5 Boilerplate is also causing complete browser shutdown crashes in IE8 on XP for me.

Please for this as soon as possible, reverting to 2.0.6 now.

After re-trying a couple of times, sometimes the browser doesn't crash but instead tries to re-load it a couple of times after failed attempts and eventually ends up at a url like res://ieframe.dll/acr_error.htm# *(domain, url). Also during the reloads it's showing a tooltip in the IE8 tab saying "This tab has been recovered".

@paulirish paulirish reopened this Feb 14, 2012

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Feb 14, 2012

Member

reopening.

@aFarkas could you look at agross's testcase?

Member

paulirish commented Feb 14, 2012

reopening.

@aFarkas could you look at agross's testcase?

@aFarkas

This comment has been minimized.

Show comment
Hide comment
@aFarkas

aFarkas Feb 14, 2012

Member

Yeah, I will look into this issue. Just downloaded the testcase and I can reproduce the issue. Will work on this tomorrow :-)

Member

aFarkas commented Feb 14, 2012

Yeah, I will look into this issue. Just downloaded the testcase and I can reproduce the issue. Will work on this tomorrow :-)

@dmethvin

This comment has been minimized.

Show comment
Hide comment
@dmethvin

dmethvin Feb 14, 2012

Contributor

This seems very similar to http://bugs.jquery.com/ticket/9823 FWIW.

Contributor

dmethvin commented Feb 14, 2012

This seems very similar to http://bugs.jquery.com/ticket/9823 FWIW.

@aFarkas

This comment has been minimized.

Show comment
Hide comment
@aFarkas

aFarkas Feb 14, 2012

Member

@dmethvin

Yeah, I'm pretty sure that this is the reason for this bug. Will look later into this and let you know.

Member

aFarkas commented Feb 14, 2012

@dmethvin

Yeah, I'm pretty sure that this is the reason for this bug. Will look later into this and let you know.

@scottjehl

This comment has been minimized.

Show comment
Hide comment
@scottjehl

scottjehl Feb 14, 2012

Contributor

Same bug used to occur with Respond.js. This change fixed it. scottjehl/Respond@8016973

Contributor

scottjehl commented Feb 14, 2012

Same bug used to occur with Respond.js. This change fixed it. scottjehl/Respond@8016973

@aFarkas

This comment has been minimized.

Show comment
Hide comment
@aFarkas

aFarkas Feb 14, 2012

Member

@dmethvin and @scottjehl

Yes it turns out this was the bug. It came from html5shiv. Actually the fakeBody isn't really needed, because we tested wether a element with a hidden property is display: none. In fact all known browsers, which have implemented the hidden property also have implemented the corresponding style. So easy to fix + less code

Member

aFarkas commented Feb 14, 2012

@dmethvin and @scottjehl

Yes it turns out this was the bug. It came from html5shiv. Actually the fakeBody isn't really needed, because we tested wether a element with a hidden property is display: none. In fact all known browsers, which have implemented the hidden property also have implemented the corresponding style. So easy to fix + less code

@aFarkas aFarkas closed this Feb 14, 2012

@necolas

This comment has been minimized.

Show comment
Hide comment
@necolas

necolas Feb 15, 2012

@scottjehl FYI: This is the fix used by jQuery - http://bugs.jquery.com/ticket/9823

@aFarkas The bug is still present in Modernizr (#501) due to a fake body being used in the tests, but looks like it can be fixed with the same fix the jQuery project used (worked for me). Thanks

necolas commented Feb 15, 2012

@scottjehl FYI: This is the fix used by jQuery - http://bugs.jquery.com/ticket/9823

@aFarkas The bug is still present in Modernizr (#501) due to a fake body being used in the tests, but looks like it can be fixed with the same fix the jQuery project used (worked for me). Thanks

@aFarkas

This comment has been minimized.

Show comment
Hide comment
@aFarkas

aFarkas Feb 15, 2012

Member

@necolas

Are you sure about this? I saw the fakeBody in Modernizr, but I didn't touched the logic there, because it worked for me in my and in your testcase (no crash). Although, I was asking myself, wether I should be more paranoid and simply setting the background style for fakeBody as well.

Member

aFarkas commented Feb 15, 2012

@necolas

Are you sure about this? I saw the fakeBody in Modernizr, but I didn't touched the logic there, because it worked for me in my and in your testcase (no crash). Although, I was asking myself, wether I should be more paranoid and simply setting the background style for fakeBody as well.

@necolas

This comment has been minimized.

Show comment
Hide comment
@necolas

necolas Feb 15, 2012

@aFarkas I don't think my testcase includes the html5shiv. Nor did jQuery 1.6.2. When I get home, I'll test again using the latest Modernizr from the repo and see if the problem remains. Thanks.

necolas commented Feb 15, 2012

@aFarkas I don't think my testcase includes the html5shiv. Nor did jQuery 1.6.2. When I get home, I'll test again using the latest Modernizr from the repo and see if the problem remains. Thanks.

aFarkas added a commit that referenced this issue Feb 15, 2012

@aFarkas

This comment has been minimized.

Show comment
Hide comment
@aFarkas

aFarkas Feb 15, 2012

Member

@necolas

Ok, I haven't used your testcase. I was using @agross's one. And in your testing Modernizr also produced this crash. Now it is fixed doubble :-). Thanks for your this.

Member

aFarkas commented Feb 15, 2012

@necolas

Ok, I haven't used your testcase. I was using @agross's one. And in your testing Modernizr also produced this crash. Now it is fixed doubble :-). Thanks for your this.

@joelhaasnoot

This comment has been minimized.

Show comment
Hide comment
@joelhaasnoot

joelhaasnoot Feb 17, 2012

This looks like a fix for my issue, but is there anyway to make a custom build of the dev version? (or when will this fix be released?)

This looks like a fix for my issue, but is there anyway to make a custom build of the dev version? (or when will this fix be released?)

@zdennis

This comment has been minimized.

Show comment
Hide comment
@zdennis

zdennis Feb 17, 2012

@aFarkas's changeset in b15f9bf fixed this issue for me. Thank you for the fix!

zdennis commented Feb 17, 2012

@aFarkas's changeset in b15f9bf fixed this issue for me. Thank you for the fix!

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Feb 17, 2012

Member

Modernizr 2.5.3 has now shipped including this fix.

http://www.modernizr.com/download/

:)

Member

paulirish commented Feb 17, 2012

Modernizr 2.5.3 has now shipped including this fix.

http://www.modernizr.com/download/

:)

@donaldjenkins

This comment has been minimized.

Show comment
Hide comment
@donaldjenkins

donaldjenkins Feb 17, 2012

Hurrah!!!! Thanks Paul.

Hurrah!!!! Thanks Paul.

@ryanve

This comment has been minimized.

Show comment
Hide comment
@ryanve

ryanve Feb 23, 2012

Contributor

Thanks everyone—it's solid now =]

Contributor

ryanve commented Feb 23, 2012

Thanks everyone—it's solid now =]

@alanfluff

This comment has been minimized.

Show comment
Hide comment
@alanfluff

alanfluff Feb 23, 2012

+1 With those thanks—here too custom 2.5.2 was crashing, custom 2.5.3 is rock solid.

:)

+1 With those thanks—here too custom 2.5.2 was crashing, custom 2.5.3 is rock solid.

:)

@kahlil

This comment has been minimized.

Show comment
Hide comment
@kahlil

kahlil Mar 9, 2012

Thanks for fixing this guys! Just spent an afternoon wondering why IE 7 and 8 were constantly crashing on me...

kahlil commented Mar 9, 2012

Thanks for fixing this guys! Just spent an afternoon wondering why IE 7 and 8 were constantly crashing on me...

@tobsch

This comment has been minimized.

Show comment
Hide comment
@tobsch

tobsch Apr 10, 2012

for me, a custom 2.5.3 is crashing ie 7.00.5730.13.
used in an iframe.

any hints on how to debug?

tobsch commented Apr 10, 2012

for me, a custom 2.5.3 is crashing ie 7.00.5730.13.
used in an iframe.

any hints on how to debug?

@ryanve

This comment has been minimized.

Show comment
Hide comment
@ryanve

ryanve Apr 11, 2012

Contributor

@tobsch Try different custom builds with different options selected to isolate which component is causing the crash. My guess is that it's the shiv or the print shiv b/c that caused the crash before. First try comparing a build with and without the shiv to see if it's the shiv. Also compare with a development build. Is the error you see the acr_error or something different?

Contributor

ryanve commented Apr 11, 2012

@tobsch Try different custom builds with different options selected to isolate which component is causing the crash. My guess is that it's the shiv or the print shiv b/c that caused the crash before. First try comparing a build with and without the shiv to see if it's the shiv. Also compare with a development build. Is the error you see the acr_error or something different?

@aFarkas

This comment has been minimized.

Show comment
Hide comment
@aFarkas

aFarkas Apr 16, 2012

Member

@tobsch
Do you have any new information on this? @ryane gave you some good starting points to look at. In case a build without html5shiv doesn't cause the crash. Also try to embed the most recent html5shiv version. You can get it here: https://github.com/aFarkas/html5shiv/blob/master/src/html5shiv.js

Member

aFarkas commented Apr 16, 2012

@tobsch
Do you have any new information on this? @ryane gave you some good starting points to look at. In case a build without html5shiv doesn't cause the crash. Also try to embed the most recent html5shiv version. You can get it here: https://github.com/aFarkas/html5shiv/blob/master/src/html5shiv.js

@gregarious

This comment has been minimized.

Show comment
Hide comment
@gregarious

gregarious Apr 19, 2012

If anyone still experiencing this issue is getting their custom builds from initializr, it's due to an outdated Respond script.

The Respond folks fixed it with this commit (scottjehl/Respond@ed8479c), but the initialzr modules using Respond still haven't pulled in these changes.

Stay tuned to verekia/initializr#43.

If anyone still experiencing this issue is getting their custom builds from initializr, it's due to an outdated Respond script.

The Respond folks fixed it with this commit (scottjehl/Respond@ed8479c), but the initialzr modules using Respond still haven't pulled in these changes.

Stay tuned to verekia/initializr#43.

patrickkettner pushed a commit to patrickkettner/Modernizr that referenced this issue Feb 22, 2015

patrickkettner pushed a commit to patrickkettner/Modernizr that referenced this issue Feb 22, 2015

patrickkettner pushed a commit to patrickkettner/Modernizr that referenced this issue Feb 22, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment