Page 1 of 1
filebot -script fn:history no longer working --SOLVED
Posted: 17 Oct 2021, 18:39
by cheaters
Code: Select all
10/17/21_13:24:52 /Users/john
$ filebot -script fn:history
Exception in thread "main" java.lang.NoClassDefFoundError: Could not initialize class net.filebot.Logging
at net.filebot.Main.main(Unknown Source)
10/17/21_13:26:08 /Users/john
$ filebot -script fn:history /Users/john/.filebot/history.xml
Exception in thread "main" java.lang.NoClassDefFoundError: Could not initialize class net.filebot.Logging
at net.filebot.Main.main(Unknown Source)
10/17/21_13:29:07 /Users/john
$ filebot -script fn:history "/Users/john/.filebot/history.xml"
Exception in thread "main" java.lang.NoClassDefFoundError: Could not initialize class net.filebot.Logging
at net.filebot.Main.main(Unknown Source)
Not sure what changed.
Just tried to clone github repo and run:
Code: Select all
10/17/21_13:44:35 /Users/john/.filebot/FileBotScriptRepo
$ filebot -script /Users/john/.filebot/FileBotScriptRepo/scripts/history.groovy | grep -v "\.srt\|\.idx\|\.sub" | tr '\t\n' '\0' | xargs -0 -n100000 basename -a | gsed '0~2 s/$/\n---/g'
Exception in thread "main" java.lang.NoClassDefFoundError: Could not initialize class net.filebot.Logging
at net.filebot.Main.main(Unknown Source)
EDIT... Actually just realized that i can't even open FileBot.app. So looks like a java issue, but I thought Java was self contained within the FileBot.app these days.
Looks like there is a regression at Homebrew. If a user has openjdk installed and is running an intel processor openjdk.rb install script is installing openjdk17 for arm processors.
EDIT... Nope not a homebrew issue. It's because I used lowercase letters in my
system.properties file when I changed from
info to
warning logging level.

Amazing that something as simple as that can prevent filebot from starting up.
Re: filebot -script fn:history no longer working --SOLVED
Posted: 18 Oct 2021, 02:59
by rednoah
The error messages above indicate that something strange is going on, as if FileBot can't access its own application data files for some reason. If it randomly starts and stops working, then there's probably some macOS strangeness to blame. The *.app bundle itself is self-contained and doesn't use
(and shouldn't even know about) whatever OpenJDK you may or may not have installed on your system.
--log is case-insensitive so all of this will work:
Code: Select all
filebot -script fn:history --log warning
Code: Select all
filebot -script fn:history --log WARNING
Code: Select all
filebot -script fn:history --log WaRnInG
--log will give you a human-readable error message if you pass in an invalid value:
Code: Select all
filebot -script fn:history --log XYZ
An unexpected error occurred during startup: Invalid --log level: 'XYZ': Bad level "XYZ"
Re: filebot -script fn:history no longer working --SOLVED
Posted: 18 Oct 2021, 03:04
by cheaters
Apparently filebot's "system.properties" is sensitive to case.
Code: Select all
/Users/user/.filebot/system.properties
this works:
this caused filebot to not startup:
Re: filebot -script fn:history no longer working --SOLVED
Posted: 18 Oct 2021, 03:59
by rednoah
Ah, yes! That explains things! If you set system properties directly, then that will bypass all the sanity checks of the command-line parser and then the error message above make sense!
EDIT:
FileBot r8885 will now gracefully catch errors that occur during logging initialization.
Re: filebot -script fn:history no longer working --SOLVED
Posted: 09 Nov 2022, 03:49
by rednoah