vlaaad / reveal

Read Eval Visualize Loop for Clojure
https://vlaaad.github.io/reveal/
MIT License
598 stars 21 forks source link

Reveal Pro crashes on startup #40

Closed dogenpunk closed 9 months ago

dogenpunk commented 1 year ago

MacOS version: 13.0.1 Clojure version: 1.11.1.1189 OpenJDK version: 11.0.17

deps.edn:

{:aliases
  {:reveal {:extra-deps {dev.vlaaad/reveal-pro {:mvn/version "1.3.351"}}
             :ns-default vlaaad.reveal
             :exec-fn repl}}}
% rlwrap clojure -X:reveal
DEPRECATED: Libs must be qualified, change deps-deploy => deps-deploy/deps-deploy (/Users/matthewnelson/.clojure/deps.edn)
DEPRECATED: Libs must be qualified, change expectations => expectations/expectations (/Users/matthewnelson/.clojure/deps.edn)
DEPRECATED: Libs must be qualified, change criterium => criterium/criterium (/Users/matthewnelson/.clojure/deps.edn)
DEPRECATED: Libs must be qualified, change proto-repl => proto-repl/proto-repl (/Users/matthewnelson/.clojure/deps.edn)
DEPRECATED: Libs must be qualified, change nrepl => nrepl/nrepl (/Users/matthewnelson/.clojure/deps.edn)
DEPRECATED: Libs must be qualified, change closh => closh/closh (/Users/matthewnelson/.clojure/deps.edn)
DEPRECATED: Libs must be qualified, change deps-deploy => deps-deploy/deps-deploy (/Users/matthewnelson/.clojure/deps.edn)
DEPRECATED: Libs must be qualified, change compliment => compliment/compliment (/Users/matthewnelson/.clojure/deps.edn)
Clojure 1.11.1
user=> 2022-11-10 11:17:37.256 java[25849:200357] *** Assertion failure in -[_NSTrackingAreaAKViewHelper removeTrackingRect:], _NSTrackingAreaAKManager.m:1585
2022-11-10 11:17:37.258 java[25849:200357] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '0x0 is an invalid NSTrackingRectTag. Common possible reasons for this are: 1. already removed this trackingRectTag, 2. Truncated the NSTrackingRectTag to 32bit at some point.'
*** First throw call stack:
(
    0   CoreFoundation                      0x00007ff80a66b43b __exceptionPreprocess + 242
    1   libobjc.A.dylib                     0x00007ff80a1bae25 objc_exception_throw + 48
    2   Foundation                          0x00007ff80b50cfb0 -[NSCalendarDate initWithCoder:] + 0
    3   AppKit                              0x00007ff80ddc8562 -[_NSTrackingAreaAKViewHelper removeTrackingRect:] + 190
    4   libglass.dylib                      0x00000001464ca4e9 -[GlassViewDelegate setFrameSize:] + 361
    5   libglass.dylib                      0x00000001464cfd68 -[GlassView3D setFrameSize:] + 88
    6   AppKit                              0x00007ff80d7543a1 -[NSView setFrame:] + 347
    7   libglass.dylib                      0x00000001464cfdc5 -[GlassView3D setFrame:] + 69
    8   AppKit                              0x00007ff80d7650f9 -[NSView resizeWithOldSuperviewSize:] + 694
    9   AppKit                              0x00007ff80d764a2a -[NSView resizeSubviewsWithOldSize:] + 488
    10  AppKit                              0x00007ff80d744206 -[NSView setFrameSize:] + 1446
    11  AppKit                              0x00007ff80d7543a1 -[NSView setFrame:] + 347
    12  AppKit                              0x00007ff80d7650f9 -[NSView resizeWithOldSuperviewSize:] + 694
    13  AppKit                              0x00007ff80d764a2a -[NSView resizeSubviewsWithOldSize:] + 488
    14  AppKit                              0x00007ff80d744206 -[NSView setFrameSize:] + 1446
    15  AppKit                              0x00007ff80d762e2d -[NSThemeFrame setFrameSize:] + 482
    16  AppKit                              0x00007ff80d7624f4 -[NSWindow _oldPlaceWindow:fromServer:] + 813
    17  AppKit                              0x00007ff80d760ae5 -[NSWindow _setFrameCommon:display:fromServer:] + 1656
    18  libglass.dylib                      0x00000001464c1acf -[GlassWindow(Java) _setFlipFrame:display:animate:] + 239
    19  libglass.dylib                      0x00000001464c15cc -[GlassWindow(Java) _setWindowFrameWithRect:withDisplay:withAnimate:] + 268
    20  libglass.dylib                      0x00000001464c181b -[GlassWindow(Java) _setBounds:y:xSet:ySet:w:h:cw:ch:] + 571
    21  libglass.dylib                      0x00000001464db2fe Java_com_sun_glass_ui_mac_MacWindow__1setBounds2 + 446
    22  ???                                 0x000000010bc74a10 0x0 + 4492577296
    23  ???                                 0x000000010bc6f267 0x0 + 4492554855
    24  ???                                 0x000000010bc6f267 0x0 + 4492554855
    25  ???                                 0x000000010bc6f267 0x0 + 4492554855
    26  ???                                 0x000000010bc6f2ac 0x0 + 4492554924
)
libc++abi: terminating with uncaught exception of type NSException

rlwrap: warning: clojure crashed, killed by SIGABRT.
rlwrap itself has not crashed, but for transparency,
it will now kill itself (without dumping core) with the same signal

warnings can be silenced by the --no-warnings (-n) option
zsh: abort      rlwrap clojure -X:reveal

Results are the same using % clojure -M:reveal and calling vlaaad.reveal/tap-log or vlaaad.reveal/repl. I've done this in a fresh directory and have deleted .cpcache on subsequent attempts.

vlaaad commented 1 year ago

It looks like a javafx-related exception in the native code on resizing the window:

rlhk commented 1 year ago

Got same/similar issue when trying out reveal free

clj \
 -Sdeps '{:deps {vlaaad/reveal {:mvn/version "1.3.276"}}}' \
 -X vlaaad.reveal/repl

openjdk 19.0.1 2022-10-18 Clojure 1.11.0 macOS Ventura 13.0.1

winterscar commented 1 year ago

Same issue for me. openjdk 17.0.7 2023-04-18 Clojure 1.11.1 macOS Ventura 13.1

vlaaad commented 1 year ago

Is it possible you guys use arm jdk?

ognen commented 10 months ago

I get the exception with an ARM idk, yes. Free version.

vlaaad commented 10 months ago

Hmm, IIRC ARM support was added to JavaFX in a version that requires Java 17. I should update cljfx to pick different JavaFX dependencies based on the JDK version (selecting between 8, 11, and 17 — currently it only does 8 and 11), then make a new Reveal release with the updated cljfx...

vlaaad commented 10 months ago

Please try Reveal version 1.3.282 to see if it fixes the issue (you should use JDK 17 or above)

dogenpunk commented 9 months ago

My results just launching from the CLI

host@local % clj \ -Sdeps '{:deps {dev.vlaaad/reveal-pro {:mvn/version "1.3.282"}}}' \ -X vlaaad.reveal/repl Error building classpath. Could not find artifact dev.vlaaad:reveal-pro:jar:1.3.282 in central (https://repo1.maven.org/maven2/) host@local % clj \ -Sdeps '{:deps {dev.vlaaad/reveal-pro {:mvn/version "1.3.359"}}}' \ -X vlaaad.reveal/repl Downloading: org/openjfx/javafx-controls/17.0.2/javafx-controls-17.0.2.pom from central Downloading: org/openjfx/javafx-graphics/17.0.2/javafx-graphics-17.0.2.pom from central Downloading: org/openjfx/javafx-base/17.0.2/javafx-base-17.0.2.pom from central Downloading: org/openjfx/javafx-media/17.0.2/javafx-media-17.0.2.pom from central Downloading: org/openjfx/javafx-web/17.0.2/javafx-web-17.0.2.pom from central Downloading: org/openjfx/javafx/17.0.2/javafx-17.0.2.pom from central Downloading: org/openjfx/javafx-base/17.0.2/javafx-base-17.0.2-mac-aarch64.jar from central Downloading: org/openjfx/javafx-media/17.0.2/javafx-media-17.0.2.jar from central Downloading: org/openjfx/javafx-graphics/17.0.2/javafx-graphics-17.0.2.jar from central Downloading: org/openjfx/javafx-controls/17.0.2/javafx-controls-17.0.2.jar from central Downloading: org/openjfx/javafx-graphics/17.0.2/javafx-graphics-17.0.2-mac-aarch64.jar from central Downloading: org/openjfx/javafx-controls/17.0.2/javafx-controls-17.0.2-mac-aarch64.jar from central Downloading: org/openjfx/javafx-base/17.0.2/javafx-base-17.0.2.jar from central Downloading: org/openjfx/javafx-media/17.0.2/javafx-media-17.0.2-mac-aarch64.jar from central Downloading: cljfx/cljfx/1.7.19/cljfx-1.7.19-jdk11.jar from clojars Downloading: org/openjfx/javafx-web/17.0.2/javafx-web-17.0.2-mac-aarch64.jar from central Downloading: org/openjfx/javafx-web/17.0.2/javafx-web-17.0.2.jar from central Clojure 1.11.1 user=>

Java Version

host@local % java -version openjdk version "17.0.7" 2023-04-18 OpenJDK Runtime Environment Temurin-17.0.7+7 (build 17.0.7+7) OpenJDK 64-Bit Server VM Temurin-17.0.7+7 (build 17.0.7+7, mixed mode)

This is on an ARM MacBook Air. MacOS 14.2.1

vlaaad commented 9 months ago

@dogenpunk 1.3.282 is reveal free, reveal pro is 1.3.363

dogenpunk commented 9 months ago

Using reveal-pro 1.3.363 works as expected on JDK 17. Thanks!