Coursier does not check that the supposedly previously installed Java installation is still present
According to the documentation, to install this on MacOS you do the following:
brew install coursier/formulas/coursier
cs setup
scala -version
This results in:
The operation couldn’t be completed. Unable to locate a Java Runtime.
Please visit http://www.java.com for information on installing Java.
I am closing this issue as a duplicate of #2537.
I don't see how this is a duplicate of #2537.
However, it was caused by having an old and incorrect:
# >>> JVM installed by coursier >>>
export JAVA_HOME=...etc...
# <<< JVM installed by coursier <<<
in my .zprofile file. That cruft was in there even though Coursier had never been installed on that machine, because the .zprofile got restored from an old backup.
I would think that Coursier should update that setting, rather than leaving the old one in there, if it see's the JVM installed by coursier bookends.
Hey, I am sorry if I mis-classified the issue. It seemed to me that both issues were caused by a common problem that the binaries are not published on some architectures (including the new Apple M1).
That being said, I am happy that you figured out the issue in your case, and I agree that it would be better if Coursier could check that the Coursier-managed JVM is indeed present.