View Single Post
Old 12-14-2020, 10:26 PM   #394
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,893
Karma: 6120478
Join Date: Nov 2009
Device: many
I just downloaded the latest and the fix was in it and everything worked just fine with my older JDK.

Went to Oracle and downloaded the very latest JDK:

java version "11.0.9" 2020-10-20 LTS
Java(TM) SE Runtime Environment 18.9 (build 11.0.9+7-LTS)
Java HotSpot(TM) 64-Bit Server VM 18.9 (build 11.0.9+7-LTS, mixed mode)

Then tried the exact same epubcheck plugin again and got the same error you are showing.

But that error is bogus. The fix was to change the user.dir property so that it did not default to root "/".

I just added some debug print statements on epubcheck and here is the user.dir value that is properly being set (which fixed the epubcheck bug we saw earlier).

-Duser.dir="/Users/kbhend/Library/Application Support/sigil-ebook/sigil/plugins/EpubCheck/"

And that is a valid existing absolute path (properly quoted for spaces). It clearly is not a relative path but this is what the error message says:

Caused by: java.lang.RuntimeException: default directory must be absolute

Well you can not get any more absolute than that. There are no symlinks in that path either.

So something seems to be broken with the very latest JDK from Oracle as that is an existing valid value for user.dir (and is much better than the previous version that set it to absolute "/" as before.

Using a subprocess in python to launch a command line java program ends with the latest JDK improperly setting its user.dir value to "/" which broke epubcheck.

Not sure how to fix this except to downgrade to and earlier version of the Java JDK on macOS.
KevinH is offline   Reply With Quote