Skip to main content

Bug Tracker

Side navigation

#9805 closed bug (invalid)

Opened July 12, 2011 08:41AM UTC

Closed July 27, 2011 07:46AM UTC

Last modified May 12, 2012 10:07PM UTC

Error in Firefox 3.6.18 with minified jquery

Reported by: software Owned by: software
Priority: low Milestone: None
Component: misc Version: 1.6.2
Keywords: Cc:
Blocked by: Blocking:
Description

I have tested our webapplication in Firefox 3.6.18, Firefox 5, IE 8 and Chrome 12.0.742.112.

This big appers only in Firefox 3.6.18 and only with jquery-1.6.2.min.js. With uncompressed version of jquery 1.6.2 (jquery-1.6.2.js) exists no problems.

Error in Firefox 3.6.18:

Error: i.exec is not a function

Sourcefile: ../jquery-1.6.2.min.js

Row: 16

"i.exec" appers only one times in jquery-1.6.2.min.js. I looking for this equivalent in jquery-1.6.2.js and founded it on row 133.

Attachments (0)
Change History (8)

Changed July 12, 2011 09:43AM UTC by addyosmani comment:1

component: unfiledmisc
owner: → software
priority: undecidedlow
status: newpending

Thanks for taking the time to contribute to the jQuery project! Please provide a complete reduced test case on jsFiddle to help us assess your ticket!

Additionally, be sure to test against the jQuery Edge version to ensure the issue still exists. To get you started, use this boilerplate: http://jsfiddle.net/FrKyN/ Open the link and click to "Fork" (in the top menu) to get started.

Changed July 27, 2011 07:46AM UTC by trac-o-bot comment:2

resolution: → invalid
status: pendingclosed

Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!

Changed August 11, 2011 04:36PM UTC by e.lestrade@nimble-apps.com comment:3

I met the same issue and solved it.

It was caused by a variable called "i" which was wrongfully global in my code. Very classic mistake:

for(i = 0; i < max; i++) {

It did interfere with the minify version of jQuery which uses a variable named "i" that Firefox 3.6.18 considers as global for an unknown reason.

The same thing happens if you use a global variable name "quickExpr" with the uncompressed version of jQuery ("quickExpr" is the uncompressed version of "i").

That is why the problem happens only with minified versions, and only with specific Firefox versions.

Juste spent 2 hours on that one. Should use jslint...

Changed October 07, 2011 05:09PM UTC by anonymous comment:4

So how did you resolve the issue? did you have to change your code, or the minified version of jquery?

Changed October 10, 2011 01:51PM UTC by fai@mugetsu.co.uk comment:5

I found the same issue too in FF 3.6.23, where the non-minified version worked fine.

To fix it, look for any "i" variables in your code and rename it to something else - i.e. iter

This cleared the issue and allowed the minified version to work again.

Typically the issue happens where jQuery is called in a scope where "i" is present (and I usually use "i" for loops - perhaps this could be corrected on the minifier?)

Changed October 10, 2011 01:59PM UTC by timmywil comment:6

I'm confused. Neither quickExpr nor i is global even in the minified version of jQuery.

Changed November 25, 2011 12:54PM UTC by anonymous comment:7

If it helps anyone, I had the same problem and after removing all instances of 'i' in my code finally traced it down to JQuery UI.

If I include jquery-ui-1.8.16.custom.min.js I get the problem - it I do not use jquery-ui-1.8.16.custom.min.js the problem goes away.

I love JQuery, but I have to ask - why on earth use i globally in your compressed library? It is just asking for trouble - IMHO this IS a bug and should be fixed.

Changed May 12, 2012 10:07PM UTC by USSR lover comment:8

Hi, I had such problem in FF 3.6.28 (and 1.5, 3.0.19). Fix - pack jquery.js with another packer. For example Dean Edvards packer., with unchecked "Base62 encode", "Shrink variables".