You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I was just trying to get OSS Review Toolkit (which uses Hoplite under the hood) to run on my machine.
Java version: openjdk 21.0.5 2024-10-15
ORT version: 46.0.0
Hoplite version (included in ORT): 2.9.0
I'm using a Macbook Pro M1 Max.
When I executed the ort command in my terminal, I got this weird issue:
Exception in thread "main" java.lang.IllegalArgumentException: key can't be empty
at java.base/java.lang.System.checkKey(System.java:1100)
at java.base/java.lang.System.getProperty(System.java:963)
at com.sksamuel.hoplite.preprocessor.EnvOrSystemPropertyPreprocessor$handle$value$1.invoke(EnvOrSystemPropertyPreprocessor.kt:33)
at com.sksamuel.hoplite.preprocessor.EnvOrSystemPropertyPreprocessor$handle$value$1.invoke(EnvOrSystemPropertyPreprocessor.kt:25)
at kotlin.text.Regex.replace(Regex.kt:194)
at com.sksamuel.hoplite.preprocessor.EnvOrSystemPropertyPreprocessor.handle(EnvOrSystemPropertyPreprocessor.kt:25)
at com.sksamuel.hoplite.preprocessor.TraversingPrimitivePreprocessor.process(Preprocessor.kt:56)
at com.sksamuel.hoplite.preprocessor.TraversingPrimitivePreprocessor.process(Preprocessor.kt:42)
at com.sksamuel.hoplite.internal.Preprocessing.process(Preprocessing.kt:29)
at com.sksamuel.hoplite.internal.Preprocessing.iterate(Preprocessing.kt:25)
at com.sksamuel.hoplite.internal.Preprocessing.preprocess(Preprocessing.kt:21)
at com.sksamuel.hoplite.internal.ConfigParser.loadResultAndContext(ConfigParser.kt:119)
at com.sksamuel.hoplite.internal.ConfigParser.<init>(ConfigParser.kt:66)
at com.sksamuel.hoplite.ConfigLoader.createConfigParser(ConfigLoader.kt:279)
at com.sksamuel.hoplite.ConfigLoader.loadConfig(ConfigLoader.kt:226)
at com.sksamuel.hoplite.ConfigLoader.loadConfig$default(ConfigLoader.kt:218)
at org.ossreviewtoolkit.model.config.OrtConfiguration$Companion.load(OrtConfiguration.kt:211)
at org.ossreviewtoolkit.model.config.OrtConfiguration$Companion.load$default(OrtConfiguration.kt:156)
at org.ossreviewtoolkit.cli.OrtMain.run(OrtMain.kt:158)
at com.github.ajalt.clikt.core.CoreCliktCommandKt.parse(CoreCliktCommand.kt:107)
at com.github.ajalt.clikt.core.CoreCliktCommandKt.main(CoreCliktCommand.kt:78)
at com.github.ajalt.clikt.core.CoreCliktCommandKt.main(CoreCliktCommand.kt:90)
at org.ossreviewtoolkit.cli.OrtMainKt.main(OrtMain.kt:91)
After several hours of debugging, I found out that the culprit is this line if my .zshrc file: source $ZSH/oh-my-zsh.sh.
When I commented it out, ORT ran normally.
Apparently, Oh My Zsh sets some system variables there and one of them turns out to be empty, which causes this line to call System.getProperty with an empty string, which in turn triggers that IllegalArgumentException.
Can you please look into this and maybe make that code more robust against such cases? Oh My Zsh is quite popular, so I might not be the only one running into that problem, and it's quite tricky to find out the cause.
The text was updated successfully, but these errors were encountered:
Hi,
So I was just trying to get OSS Review Toolkit (which uses Hoplite under the hood) to run on my machine.
I'm using a Macbook Pro M1 Max.
When I executed the ort command in my terminal, I got this weird issue:
After several hours of debugging, I found out that the culprit is this line if my .zshrc file:
source $ZSH/oh-my-zsh.sh
.When I commented it out, ORT ran normally.
Apparently, Oh My Zsh sets some system variables there and one of them turns out to be empty, which causes this line to call
System.getProperty
with an empty string, which in turn triggers that IllegalArgumentException.Can you please look into this and maybe make that code more robust against such cases? Oh My Zsh is quite popular, so I might not be the only one running into that problem, and it's quite tricky to find out the cause.
The text was updated successfully, but these errors were encountered: