philcali/sbt-cx-docco — Issue #2: Backtick ( ` ) in docco causes java.lang.NoSuchMethodError
Author: vjpr
Created: 2011-10-19 17:29:47+00:00
State: open

When I try to do inline code snippets by surrounding some text in bacticks I get the following stack trace. Any ideas?

**Input**

/*! This is some `code` */

**Stack Trace**

[info] Generating docco's now...
java.lang.reflect.InvocationTargetException
at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at ru.circumflex.freemarker.ScalaBaseWrapper.get(wrappers.scala:158)
at freemarker.core.Dot._getAsTemplateModel(Dot.java:76)
at freemarker.core.Expression.getAsTemplateModel(Expression.java:89)
at freemarker.core.Expression.getStringValue(Expression.java:93)
at freemarker.core.DollarVariable.accept(DollarVariable.java:76)
at freemarker.core.Environment.visit(Environment.java:210)
at freemarker.core.MixedContent.accept(MixedContent.java:92)
at freemarker.core.Environment.visit(Environment.java:210)
at freemarker.core.IteratorBlock$Context.runLoop(IteratorBlock.java:179)
at freemarker.core.Environment.visit(Environment.java:417)
at freemarker.core.IteratorBlock.accept(IteratorBlock.java:102)
at freemarker.core.Environment.visit(Environment.java:210)
at freemarker.core.MixedContent.accept(MixedContent.java:92)
at freemarker.core.Environment.visit(Environment.java:210)
at freemarker.core.Environment.process(Environment.java:190)
at freemarker.template.Template.process(Template.java:237)
at ru.circumflex.docco.DoccoBatch$$anonfun$15.apply(docco.scala:247)
at ru.circumflex.docco.DoccoBatch$$anonfun$15.apply(docco.scala:234)
at scala.collection.TraversableLike$$anonfun$flatMap$1.apply(TraversableLike.scala:200)
at scala.collection.TraversableLike$$anonfun$flatMap$1.apply(TraversableLike.scala:200)
at scala.collection.LinearSeqOptimized$class.foreach(LinearSeqOptimized.scala:59)
at scala.collection.immutable.List.foreach(List.scala:45)
at scala.collection.generic.TraversableForwarder$class.foreach(TraversableForwarder.scala:30)
at scala.collection.mutable.ListBuffer.foreach(ListBuffer.scala:42)
at scala.collection.TraversableLike$class.flatMap(TraversableLike.scala:200)
at scala.collection.mutable.ListBuffer.flatMap(ListBuffer.scala:42)
at ru.circumflex.docco.DoccoBatch.generate(docco.scala:234)
at DoccoPlugin$$anonfun$doccoSettings$8.apply(DoccoProject.scala:123)
at DoccoPlugin$$anonfun$doccoSettings$8.apply(DoccoProject.scala:120)
at scala.Function1$$anonfun$compose$1.apply(Function1.scala:41)
at scala.Function1$$anonfun$compose$1.apply(Function1.scala:41)
at sbt.$tilde$greater$$anonfun$$u2219$1.apply(TypeFunctions.scala:40)
at sbt.std.Transform$$anon$5.work(System.scala:67)
at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:221)
at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:221)
at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:13)
at sbt.Execute.work(Execute.scala:227)
at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:221)
at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:221)
at sbt.CompletionService$$anon$1$$anon$2.call(CompletionService.scala:26)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:680)
Caused by: java.lang.NoSuchMethodError: scala.runtime.RichInt.until(I)Lscala/collection/immutable/Range$ByOne;
at ru.circumflex.markeven.Protector.randomKey(util.scala:16)
at ru.circumflex.markeven.Protector.addToken(util.scala:23)
at ru.circumflex.markeven.MarkevenProcessor$$anonfun$doCodeSpans$1.apply(processor.scala:727)
at ru.circumflex.markeven.MarkevenProcessor$$anonfun$doCodeSpans$1.apply(processor.scala:723)
at ru.circumflex.markeven.StringEx.replaceAll(util.scala:78)
at ru.circumflex.markeven.MarkevenProcessor.doCodeSpans(processor.scala:723)
at ru.circumflex.markeven.MarkevenProcessor.transform(processor.scala:697)
at ru.circumflex.markeven.ParagraphBlock.processContent(blocks.scala:133)
at ru.circumflex.markeven.Block.toHtml(blocks.scala:43)
at ru.circumflex.markeven.Block.writeHtml(blocks.scala:58)
at ru.circumflex.markeven.MarkevenProcessor$$anonfun$writeHtml$1.apply(processor.scala:830)
at ru.circumflex.markeven.MarkevenProcessor$$anonfun$writeHtml$1.apply(processor.scala:829)
at scala.collection.LinearSeqOptimized$class.foreach(LinearSeqOptimized.scala:59)
at scala.collection.immutable.List.foreach(List.scala:45)
at scala.collection.generic.TraversableForwarder$class.foreach(TraversableForwarder.scala:30)
at scala.collection.mutable.ListBuffer.foreach(ListBuffer.scala:42)
at ru.circumflex.markeven.MarkevenProcessor.writeHtml(processor.scala:829)
at ru.circumflex.markeven.MarkevenProcessor.process(processor.scala:689)
at ru.circumflex.markeven.MarkevenProcessor.toHtml(processor.scala:847)
at ru.circumflex.markeven.package$.toHtml(package.scala:45)
at ru.circumflex.docco.Section.doc(docco.scala:36)
at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at ru.circumflex.freemarker.ScalaBaseWrapper.get(wrappers.scala:158)
at freemarker.core.Dot._getAsTemplateModel(Dot.java:76)
at freemarker.core.Expression.getAsTemplateModel(Expression.java:89)
at freemarker.core.Expression.getStringValue(Expression.java:93)
at freemarker.core.DollarVariable.accept(DollarVariable.java:76)
at freemarker.core.Environment.visit(Environment.java:210)
at freemarker.core.MixedContent.accept(MixedContent.java:92)
at freemarker.core.Environment.visit(Environment.java:210)
at freemarker.core.IteratorBlock$Context.runLoop(IteratorBlock.java:179)
at freemarker.core.Environment.visit(Environment.java:417)
at freemarker.core.IteratorBlock.accept(IteratorBlock.java:102)
at freemarker.core.Environment.visit(Environment.java:210)
at freemarker.core.MixedContent.accept(MixedContent.java:92)
at freemarker.core.Environment.visit(Environment.java:210)
at freemarker.core.Environment.process(Environment.java:190)
at freemarker.template.Template.process(Template.java:237)
at ru.circumflex.docco.DoccoBatch$$anonfun$15.apply(docco.scala:247)
at ru.circumflex.docco.DoccoBatch$$anonfun$15.apply(docco.scala:234)
at scala.collection.TraversableLike$$anonfun$flatMap$1.apply(TraversableLike.scala:200)
at scala.collection.TraversableLike$$anonfun$flatMap$1.apply(TraversableLike.scala:200)
at scala.collection.LinearSeqOptimized$class.foreach(LinearSeqOptimized.scala:59)
at scala.collection.immutable.List.foreach(List.scala:45)
at scala.collection.generic.TraversableForwarder$class.foreach(TraversableForwarder.scala:30)
at scala.collection.mutable.ListBuffer.foreach(ListBuffer.scala:42)
at scala.collection.TraversableLike$class.flatMap(TraversableLike.scala:200)
at scala.collection.mutable.ListBuffer.flatMap(ListBuffer.scala:42)
at ru.circumflex.docco.DoccoBatch.generate(docco.scala:234)
at DoccoPlugin$$anonfun$doccoSettings$8.apply(DoccoProject.scala:123)
at DoccoPlugin$$anonfun$doccoSettings$8.apply(DoccoProject.scala:120)
at scala.Function1$$anonfun$compose$1.apply(Function1.scala:41)
at scala.Function1$$anonfun$compose$1.apply(Function1.scala:41)
at sbt.$tilde$greater$$anonfun$$u2219$1.apply(TypeFunctions.scala:40)
at sbt.std.Transform$$anon$5.work(System.scala:67)
at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:221)
at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:221)
at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:13)
at sbt.Execute.work(Execute.scala:227)
at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:221)
at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:221)
at sbt.CompletionService$$anon$1$$anon$2.call(CompletionService.scala:26)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:680)