This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 6 - Pages: 1 - Last Post: 21-Jul-2019 17:43 Last Post By: ctwist
AndreWolff

Posts: 1,714
Registered: 14-Dec-2007
Mirage: NullPointerException in index.htt at line number 207
Posted: 20-Jul-2019 16:49
 
  Click to reply to this thread Reply
I was testing the Mirage skin, because this skin calls also a SaveUI function which gives problems in my skins, see here.

However my test did result in a crash:
e.datadosen.util.ScriptException: java.lang.NullPointerException in index.htt at line number 207
	at se.datadosen.util.ScriptException.of(ScriptException.java:59)
	at se.datadosen.jalbum.ast.ScriptletNode.doEval(ScriptletNode.java:75)
	at se.datadosen.jalbum.ast.ASTNode.eval(ASTNode.java:50)
	at se.datadosen.jalbum.ast.GroupNode.doEval(GroupNode.java:78)
	at se.datadosen.jalbum.ast.IteratorNode.handleIteration(IteratorNode.java:109)
	at se.datadosen.jalbum.ast.IteratorNode.doEval(IteratorNode.java:97)
	at se.datadosen.jalbum.ast.ASTNode.eval(ASTNode.java:50)
	at se.datadosen.jalbum.ast.GroupNode.doEval(GroupNode.java:78)
	at se.datadosen.jalbum.ast.ASTNode.eval(ASTNode.java:50)
	at se.datadosen.jalbum.AST.eval(AST.java:75)
	at se.datadosen.jalbum.AlbumBean.makeIndexPages(AlbumBean.java:3194)
	at se.datadosen.jalbum.AlbumBean.makeAlbumForFolder(AlbumBean.java:1475)
	at se.datadosen.jalbum.AlbumBean.makeAlbum(AlbumBean.java:2754)
	at se.datadosen.jalbum.AlbumBean.smartMakeAlbum(AlbumBean.java:2666)
	at se.datadosen.jalbum.JAlbumFrame$6.run(JAlbumFrame.java:1101)
Caused by: javax.script.ScriptException: bsh.TargetError: Sourced file: inline evaluation of: ``  				index.fAoSetup();          vIsVariant = index.vIsVariant;  				vAoCat = in . . . '' : Method Invocation index.fAoSetup : at Line: 2 : in file: inline evaluation of: ``  				index.fAoSetup();          vIsVariant = index.vIsVariant;  				vAoCat = in . . . '' : index .fAoSetup ( ) 
 
Target exception: java.lang.NullPointerException
 in inline evaluation of: ``  				index.fAoSetup();          vIsVariant = index.vIsVariant;  				vAoCat = in . . . '' at line number 2
	at bsh.BshScriptEngine.evalSource(BshScriptEngine.java:90)
	at bsh.BshScriptEngine.eval(BshScriptEngine.java:57)
	at java.scripting/javax.script.AbstractScriptEngine.eval(Unknown Source)
	at se.datadosen.jalbum.ast.ScriptletNode.doEval(ScriptletNode.java:54)
	... 13 more
Caused by: java.lang.NullPointerException
	at MgAlbumObject.fProcessWebloc(MgAlbumObject.java:1124)
	at MgAlbumObject.initExtras(MgAlbumObject.java:410)
	at MgAlbumObject.<init>(MgAlbumObject.java:173)
	at Index.fAoSetup(Index.java:771)
	at jdk.internal.reflect.GeneratedMethodAccessor74.invoke(Unknown Source)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.base/java.lang.reflect.Method.invoke(Unknown Source)
	at bsh.Reflect.invokeMethod(Reflect.java:146)
	at bsh.Reflect.invokeObjectMethod(Reflect.java:79)
	at bsh.Name.invokeMethod(Name.java:859)
	at bsh.BSHMethodInvocation.eval(BSHMethodInvocation.java:75)
	at bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:102)
	at bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:47)
	at bsh.Interpreter.eval(Interpreter.java:672)
	at bsh.Interpreter.eval(Interpreter.java:766)
	at bsh.Interpreter.eval(Interpreter.java:755)
	at bsh.BshScriptEngine.evalSource(BshScriptEngine.java:82)
	... 16 more
ctwist

Posts: 557
Registered: 27-Sep-2003
Re: Mirage: NullPointerException in index.htt at line number 207
Posted: 20-Jul-2019 20:11   in response to: AndreWolff in response to: AndreWolff
 
  Click to reply to this thread Reply
MIrage fails when processing a YouTube web location. Could you provide the YouTube URL so that I can investigate?
jGromit

Posts: 7,509
Registered: 31-Jan-2006
Re: Mirage: NullPointerException in index.htt at line number 207
Posted: 20-Jul-2019 20:30   in response to: ctwist in response to: ctwist
 
  Click to reply to this thread Reply
Looks like it's the form of the URL that matters.

This fails: https://www.youtube.com/embed/Bj-7LxpF9dA

This works: https://youtu.be/Bj-7LxpF9dA
AndreWolff

Posts: 1,714
Registered: 14-Dec-2007
Re: Mirage: NullPointerException in index.htt at line number 207
Posted: 21-Jul-2019 08:43   in response to: ctwist in response to: ctwist
 
  Click to reply to this thread Reply
ctwist wrote:
MIrage fails when processing a YouTube web location. Could you provide the YouTube URL so that I can investigate?

I did test it with this album which contains these external videos:

https://player.vimeo.com/video/74152497
https://youtu.be/7mYdQa_Ohzw
https://www.youtube.com/embed/QbULyApj9Sw

It was also a little weird I think that I had to remove spaces from image filenames to test these pictures with your skin.
ctwist

Posts: 557
Registered: 27-Sep-2003
Re: Mirage: NullPointerException in index.htt at line number 207
Posted: 21-Jul-2019 15:29   in response to: AndreWolff in response to: AndreWolff
 
  Click to reply to this thread Reply
Attachment mirage.jar (120.0 KB)
The attached file fixes the bug. I will issue a skin update soon.

AndreWolff wrote:
It was also a little weird I think that I had to remove spaces from image filenames to test these pictures with your skin.

In the Mirage settings, on the General tab, there is an option to allow spaces in file names. I added this option in the old days when spaces caused a problem in Linux.
In the next skin update, I will enable this option by default.
jGromit

Posts: 7,509
Registered: 31-Jan-2006
Re: Mirage: NullPointerException in index.htt at line number 207
Posted: 21-Jul-2019 16:00   in response to: ctwist in response to: ctwist
 
  Click to reply to this thread Reply
ctwist wrote:
In the Mirage settings, on the General tab, there is an option to allow spaces in file names. I added this option in the old days when spaces caused a problem in Linux.
In the next skin update, I will enable this option by default.

Or maybe just remove the checkbox entirely. Especially now that jAlbum is automatically URL-encoding all links, spaces shouldn't be an issue in any situation I can think of, unless Mirage is generating some non-encoded links on its own - they would probably work, but the page would fail validation.
ctwist

Posts: 557
Registered: 27-Sep-2003
Re: Mirage: NullPointerException in index.htt at line number 207
Posted: 21-Jul-2019 17:43   in response to: jGromit in response to: jGromit
 
  Click to reply to this thread Reply
jGromit wrote:
Or maybe just remove the checkbox entirely.
Maybe you are right; I will think about it.
Legend
Forum admins
Helpful Answer
Correct Answer

Point your RSS reader here for a feed of the latest messages in all forums