Skip to content
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

RangeError: Invalid array length when linting a specific file #1375

Closed
mcomella opened this issue Nov 20, 2013 · 2 comments
Closed

RangeError: Invalid array length when linting a specific file #1375

mcomella opened this issue Nov 20, 2013 · 2 comments
Milestone

Comments

@mcomella
Copy link

When linting this file with jshint v2.3.0 (Arch Linux) and the moz config option enabled, I receive the following error:

/usr/lib/node_modules/jshint/src/jshint.js:4882
                                throw err;
                                      ^
RangeError: Invalid array length
    at Function._.zip (/usr/lib/node_modules/jshint/node_modules/underscore/underscore.js:495:19)
    at destructuringExpressionMatch (/usr/lib/node_modules/jshint/src/jshint.js:3220:6)
    at Object.fud (/usr/lib/node_modules/jshint/src/jshint.js:3438:6)
    at expression (/usr/lib/node_modules/jshint/src/jshint.js:958:29)
    at statement (/usr/lib/node_modules/jshint/src/jshint.js:1684:7)
    at statements (/usr/lib/node_modules/jshint/src/jshint.js:1733:12)
    at block (/usr/lib/node_modules/jshint/src/jshint.js:1861:9)
    at Object.t [as fud] (/usr/lib/node_modules/jshint/src/jshint.js:3633:3)
    at expression (/usr/lib/node_modules/jshint/src/jshint.js:958:29)
    at statement (/usr/lib/node_modules/jshint/src/jshint.js:1684:7)
@rwaldron
Copy link
Member

Same issue in the web-based jshint. Removing the destructuring lines stops the error:

  • let [ mimeType, icon ] = yield downloadIcon(this.iconURI);
  • let [ mimeType, icon ] = yield downloadIcon(iconURI);
  • let [ oldUniqueName, installPath ] = WebappOSUtils.getLaunchTarget(this.app);

@valueof
Copy link
Member

valueof commented Dec 21, 2013

Fixed both in 2.x and master.

@valueof valueof closed this as completed Dec 21, 2013
jugglinmike pushed a commit to jugglinmike/jshint that referenced this issue Oct 21, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants