yui / yuidoc

YUI Javascript Documentation Tool
http://yui.github.com/yuidoc
Other
891 stars 210 forks source link

Uncaught YUIDoc error #105

Open jwerre opened 11 years ago

jwerre commented 11 years ago
info: (builder): Preparing index.html
info: (builder): Writing API Meta Data
info: (builder): Finished writing module files
info: (builder): Rendering and writing 18 class pages.
error: --------------------------------------------------------------------------
error: An uncaught YUIDoc error has occurred, stack trace given below
error: --------------------------------------------------------------------------
error: 
TypeError: Object 1 has no method 'indexOf'
    at Object.YUI.add.Y.DocBuilder.Y.Handlebars.registerHelper.str (/usr/local/lib/node_modules/yuidocjs/lib/builder.js:67:22)
    at program4 (eval at <anonymous> (/usr/local/lib/node_modules/yuidocjs/node_modules/yui/handlebars-compiler/handlebars-compiler-min.js:12:21656))
    at Object.YUI.add.n.VM.program [as fn] (/usr/local/lib/node_modules/yuidocjs/node_modules/yui/handlebars-base/handlebars-base-min.js:12:2305)
    at Object.YUI.add.n.registerHelper.r (/usr/local/lib/node_modules/yuidocjs/node_modules/yui/handlebars-base/handlebars-base-min.js:12:954)
    at Object.eval (eval at <anonymous> (/usr/local/lib/node_modules/yuidocjs/node_modules/yui/handlebars-compiler/handlebars-compiler-min.js:12:21656))
    at Object.YUI.add.n.VM.template (/usr/local/lib/node_modules/yuidocjs/node_modules/yui/handlebars-base/handlebars-base-min.js:12:2050)
    at Object.YUI.add.n.compile [as classes] (/usr/local/lib/node_modules/yuidocjs/node_modules/yui/handlebars-compiler/handlebars-compiler-min.js:12:28480)
    at Object.YUI.add.n.VM.invokePartial (/usr/local/lib/node_modules/yuidocjs/node_modules/yui/handlebars-base/handlebars-base-min.js:12:2680)
    at Object.eval (eval at <anonymous> (/usr/local/lib/node_modules/yuidocjs/node_modules/yui/handlebars-compiler/handlebars-compiler-min.js:12:21656))
    at Object.YUI.add.n.VM.template (/usr/local/lib/node_modules/yuidocjs/node_modules/yui/handlebars-base/handlebars-base-min.js:12:2050)
error: --------------------------------------------------------------------------
error: Node.js version: v0.8.14
error: YUI version: 3.8.0pr2
error: YUIDoc version: 0.3.35
error: Please file all tickets here: http://github.com/yui/yuidoc/issues
error: --------------------------------------------------------------------------
jwerre commented 11 years ago

I was using the @extends without specifying the extended class. Problem solved but it would be nice to know where the error is occurring so you can track it down a little more easily.

davglass commented 11 years ago

Thanks, I'll look into this.

teknico commented 11 years ago

I have a similar error, and no idea of where to look for the problem:

info: (yuidoc): Starting YUIDoc with the following options:
info: (yuidoc): 
{ port: 3000,
  nocode: true,
  outdir: 'yuidoc',
  exclude: 'assets',
  paths: [ 'app' ],
  parseOnly: true,
  nocolor: true }
info: (yuidoc): YUIDoc Starting from: app
error: --------------------------------------------------------------------------
error: An uncaught YUIDoc error has occurred, stack trace given below
error: --------------------------------------------------------------------------
error: 
TypeError: Cannot set property 'module' of undefined
    at DIGESTERS.class (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yuidocjs/lib/docparser.js:505:29)
    at null.<anonymous> (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yuidocjs/lib/docparser.js:1259:40)
    at Array.forEach (native)
    at Function.YArray.each.YArray.forEach.Lang._isNative.i (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yui/yui-nodejs/yui-nodejs.js:2194:20)
    at a (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yui/oop/oop-min.js:2:129)
    at e.each (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yui/oop/oop-min.js:2:1133)
    at Y.extend.processblock (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yuidocjs/lib/docparser.js:1225:15)
    at null.<anonymous> (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yuidocjs/lib/docparser.js:1315:26)
    at Array.forEach (native)
    at Function.YArray.each.YArray.forEach.Lang._isNative.i (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yui/yui-nodejs/yui-nodejs.js:2194:20)
    at a (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yui/oop/oop-min.js:2:129)
    at e.each (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yui/oop/oop-min.js:2:1133)
    at null.<anonymous> (/home/nl/canonical/CloudEng/code/juju-gui/fix-code-doc-crash/node_modules/yuidocjs/lib/docparser.js:1314:19)
error: --------------------------------------------------------------------------
error: Node.js version: v0.10.7
error: YUI version: 3.9.1
error: YUIDoc version: 0.3.42
error: Please file all tickets here: http://github.com/yui/yuidoc/issues
error: --------------------------------------------------------------------------
jwerre commented 11 years ago

I suggest using the --server option, that way when you have an error there survey will spit out an error.

teknico commented 11 years ago

Thanks for the suggestion, jwerre. However the traceback shown via the --server option is the same unsuggestive one as shown before.

For the record, the problem was a valueless @ tag. I hereby renew my plea for better error diagnostics. Thank you. :-)

zebulonj commented 11 years ago

+1 to the request for better error diagnostics. Otherwise, love this tool.