deck2pdf icon indicating copy to clipboard operation
deck2pdf copied to clipboard

Exception in thread "JavaFX Application Thread" netscape.javascript.JSException: ReferenceError: Can't find variable: Reveal

Open goerge opened this issue 8 years ago • 2 comments

When executing ./deck2pdf --profile=revealjs presentation.html deck.pdf, the "PDF Export Web View" window opens and shows my presentation and after a second or two, I get the following stacktrace:

Error while executing the following code:
Reveal.configure({controls: false, progress: false});
Exception in thread "JavaFX Application Thread" netscape.javascript.JSException: ReferenceError: Can't find variable: Reveal
        at com.sun.webkit.dom.JSObject.fwkMakeException(JSObject.java:128)
        at com.sun.webkit.WebPage.twkExecuteScript(Native Method)
        at com.sun.webkit.WebPage.executeScript(WebPage.java:1439)
        at javafx.scene.web.WebEngine.executeScript(WebEngine.java:982)
        at me.champeau.deck2pdf.GroovyProfile.executeJS(GroovyProfile.java:65)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:497)
        at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:93)
        at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1210)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1077)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1019)
        at groovy.lang.MetaClassImpl.invokePropertyOrMissing(MetaClassImpl.java:1256)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1212)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1019)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:810)
        at groovy.lang.GroovyObjectSupport.invokeMethod(GroovyObjectSupport.java:46)
        at groovy.lang.Script.invokeMethod(Script.java:80)
        at org.codehaus.groovy.runtime.metaclass.ClosureMetaClass.invokeOnDelegationObjects(ClosureMetaClass.java:430)
        at org.codehaus.groovy.runtime.metaclass.ClosureMetaClass.invokeMethod(ClosureMetaClass.java:369)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1019)
        at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.callCurrent(PogoMetaClassSite.java:69)
        at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:52)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:154)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:166)
        at Script1$_run_closure3.doCall(Script1.groovy:11)
        at Script1$_run_closure3.doCall(Script1.groovy)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:497)
        at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:93)
        at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:325)
        at org.codehaus.groovy.runtime.metaclass.ClosureMetaClass.invokeMethod(ClosureMetaClass.java:294)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1019)
        at groovy.lang.Closure.call(Closure.java:426)
        at groovy.lang.Closure.call(Closure.java:420)
        at me.champeau.deck2pdf.GroovyProfile.setup(GroovyProfile.java:123)
        at me.champeau.deck2pdf.Browser.lambda$doExport$1(Browser.java:134)
        at com.sun.javafx.binding.ExpressionHelper$SingleChange.fireValueChangedEvent(ExpressionHelper.java:182)
        at com.sun.javafx.binding.ExpressionHelper.fireValueChangedEvent(ExpressionHelper.java:81)
        at javafx.beans.property.ReadOnlyObjectWrapper$ReadOnlyPropertyImpl.fireValueChangedEvent(ReadOnlyObjectWrapper.java:176)
        at javafx.beans.property.ReadOnlyObjectWrapper.fireValueChangedEvent(ReadOnlyObjectWrapper.java:142)
        at javafx.beans.property.ObjectPropertyBase.markInvalid(ObjectPropertyBase.java:112)
        at javafx.beans.property.ObjectPropertyBase.set(ObjectPropertyBase.java:146)
        at javafx.scene.web.WebEngine$LoadWorker.updateState(WebEngine.java:1260)
        at javafx.scene.web.WebEngine$LoadWorker.dispatchLoadEvent(WebEngine.java:1371)
        at javafx.scene.web.WebEngine$LoadWorker.access$1200(WebEngine.java:1253)
        at javafx.scene.web.WebEngine$PageLoadListener.dispatchLoadEvent(WebEngine.java:1240)
        at com.sun.webkit.WebPage.fireLoadEvent(WebPage.java:2400)
        at com.sun.webkit.WebPage.fwkFireLoadEvent(WebPage.java:2244)
        at com.sun.webkit.network.URLLoader.twkDidFinishLoading(Native Method)
        at com.sun.webkit.network.URLLoader.notifyDidFinishLoading(URLLoader.java:838)
        at com.sun.webkit.network.URLLoader.lambda$didFinishLoading$96(URLLoader.java:829)
        at com.sun.javafx.application.PlatformImpl.lambda$null$174(PlatformImpl.java:295)
        at java.security.AccessController.doPrivileged(Native Method)
        at com.sun.javafx.application.PlatformImpl.lambda$runLater$175(PlatformImpl.java:294)
        at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95)

Any idea? Do you need further information or shall I try to create a minimal slide deck to reproduce the error?

goerge avatar Oct 15 '16 20:10 goerge

I get this exception too with revealjs profile.

joel-porquet avatar Jan 20 '17 19:01 joel-porquet

Did you ever find an answer to this? I have the same problem. Running with the deck2pdf.bat on Win10 it opens a pdfviewer but gives the same errors in the shell

student1304 avatar Jul 27 '20 20:07 student1304