reveal 2021-04-30

Hi there, I am trying to use reveal for the first time and I am getting this error

Downloading: borkdude/edamame/0.0.11-alpha.28/edamame-0.0.11-alpha.28.pom from clojars
Downloading: borkdude/edamame/0.0.11-alpha.28/edamame-0.0.11-alpha.28.jar from clojars
Downloading: borkdude/sci/0.2.1-alpha.1/sci-0.2.1-alpha.1.jar from clojars
Downloading: zprint/zprint/1.1.1/zprint-1.1.1.jar from clojars
Syntax error (ClassNotFoundException) compiling at (cljfx/coerce.clj:1:1).
javafx.event.EventHandler

@richiardiandrea where is the sdk command coming from?

sdkman I believe

❤️ 1

Hmm. I tried sdkman and it's great for managing java installations

However, using java 8.0.282.fx-zulu still results in

(require 'vlaaad.reveal)
=> nil
(add-tap (vlaaad.reveal/ui))
Syntax error (IllegalArgumentException) compiling . at (cljfx/jdk/platform.clj:6:5).
No matching method startup found taking 1 args for class javafx.application.Platform

are you using tools-deps? you might need to clear .cpcache first

I am, tried that. Also deleted gitlibs and m2 to be sure. But let me try it in an empty project

hmm interesting. it worked with the empty project

I'll need to look at my dep tree

maybe you deleted wrong .cpcache?

or at the wrong time

deletion has to happen after changing the jdk

I did some more investigation and it appears to be specific to launching the repl from Cursive

Can you show your run configuration?

Also does cursive project use this zulu jdk? Cursive jdk is not the same as cli java version

Yeah, I set the project sdk to that zulu one

Here's the run config. Went for clojure.main with deps to be as barebones as possible.

And the entire repl output:

Starting clojure.main REPL...
/Users/ikoszo/.sdkman/candidates/java/8.0.282.fx-zulu/zulu-8.jdk/Contents/Home/bin/java -Dclojure.libfile=/private/var/folders/yq/pzs9fnnj5g715j73kxglggcjtyvz55/T/libfile5.libs "-javaagent:/Applications/IntelliJ IDEA 2020.1 CE  IDEA 2020.1 CE " -Dfile.encoding=UTF-8 -classpath src:/Users/ikoszo/.m2/repository/org/clojure/clojure/1.10.3/clojure-1.10.3.jar:/Users/ikoszo/.m2/repository/vlaaad/reveal/1.3.209/reveal-1.3.209.jar:/Users/ikoszo/.m2/repository/org/clojure/core.specs.alpha/0.2.56/core.specs.alpha-0.2.56.jar:/Users/ikoszo/.m2/repository/org/clojure/spec.alpha/0.2.194/spec.alpha-0.2.194.jar:/Users/ikoszo/.m2/repository/cljfx/cljfx/1.7.12/cljfx-1.7.12.jar:/Users/ikoszo/.m2/repository/cljfx/css/1.1.0/css-1.1.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark/0.62.0/flexmark-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-ext-autolink/0.62.0/flexmark-ext-autolink-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-ext-wikilink/0.62.0/flexmark-ext-wikilink-0.62.0.jar:/Users/ikoszo/.m2/repository/org/apache/commons/commons-lang3/3.10/commons-lang3-3.10.jar:/Users/ikoszo/.m2/repository/cljfx/cljfx/1.7.12/cljfx-1.7.12-jdk11.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-base/15.0.1/javafx-base-15.0.1.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-controls/15.0.1/javafx-controls-15.0.1.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-graphics/15.0.1/javafx-graphics-15.0.1.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-media/15.0.1/javafx-media-15.0.1.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-web/15.0.1/javafx-web-15.0.1.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-ast/0.62.0/flexmark-util-ast-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-builder/0.62.0/flexmark-util-builder-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-collection/0.62.0/flexmark-util-collection-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-data/0.62.0/flexmark-util-data-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-dependency/0.62.0/flexmark-util-dependency-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-format/0.62.0/flexmark-util-format-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-html/0.62.0/flexmark-util-html-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-misc/0.62.0/flexmark-util-misc-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-sequence/0.62.0/flexmark-util-sequence-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-visitor/0.62.0/flexmark-util-visitor-0.62.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util/0.62.0/flexmark-util-0.62.0.jar:/Users/ikoszo/.m2/repository/org/nibor/autolink/autolink/0.6.0/autolink-0.6.0.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-base/15.0.1/javafx-base-15.0.1-mac.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-controls/15.0.1/javafx-controls-15.0.1-mac.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-graphics/15.0.1/javafx-graphics-15.0.1-mac.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-media/15.0.1/javafx-media-15.0.1-mac.jar:/Users/ikoszo/.m2/repository/org/openjfx/javafx-web/15.0.1/javafx-web-15.0.1-mac.jar:/Users/ikoszo/.m2/repository/org/jetbrains/annotations/15.0/annotations-15.0.jar:/Users/ikoszo/.m2/repository/com/vladsch/flexmark/flexmark-util-options/0.62.0/flexmark-util-options-0.62.0.jar clojure.main -r
Clojure 1.10.3
user=> (do
  (require 'vlaaad.reveal)
  (add-tap (vlaaad.reveal/ui)))
Syntax error (IllegalArgumentException) compiling . at (cljfx/jdk/platform.clj:6:5).
No matching method startup found taking 1 args for class javafx.application.Platform
user=> 

I raised this in #cursive as I think it's more an issue on that end

yes it's sdk man, it worked on my side with cider but it's not usable cause the jdk 8 + fx does not seem to handle GDK_SCALE well

Are you on java 8?

Looks like a jdk without javafx built in

Using java 8, you need a jdk that bundles javafx.

I vlaad thanks, I have just googled around and I see, yes I am on java 8

huge thread here https://stackoverflow.com/questions/18547362/javafx-and-openjdk seems like a non-trivial thing to do 😄 Will read that

TL;DR: for Java 8, either use Oracle’s JDK (ugh!) or Azul Systems’ Zulu JDK 8 with the JavaFX bundle.

yep it looks like Zulu is what i want 😄

sdk install java 8.0.282.fx-zulu worked!

👍 1
👍🏻 1

has anybody ever seen this?

the command cider is running is

clojure -M:reveal:dev -Sdeps '{:deps {nrepl/nrepl {:mvn/version "0.8.3"} cider/cider-nrepl {:mvn/version "0.26.0"}} :aliases {:cider/nrepl {:main-opts ["-m" "nrepl.cmdline" "--middleware" "[cider.nrepl/cider-middleware,vlaaad.reveal.nrepl/middleware]"]}}}' -M:cider/nrepl