Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MacOS/GLMakie: NSException when displaying GLMakie figure #4688

Open
3 tasks done
asinghvi17 opened this issue Dec 22, 2024 · 1 comment
Open
3 tasks done

MacOS/GLMakie: NSException when displaying GLMakie figure #4688

asinghvi17 opened this issue Dec 22, 2024 · 1 comment
Labels
bug GLMakie This relates to GLMakie.jl, the OpenGL backend for Makie. macOS For issues involving macOS and the M-series processor regression This issue describes a regression from a previous version or commit.

Comments

@asinghvi17
Copy link
Member

asinghvi17 commented Dec 22, 2024

  • what version of Makie are you running? (]st -m Makie) master
  • can you reproduce the bug with a fresh environment ? (]activate --temp; add Makie)
  • What platform + GPU are you on? Mac M1

I randomly get uncaught SIGABRTs when displaying figures on Mac M1 with GLMakie:

julia> using GLMakie

julia> fig = Figure()
*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'NSWindow should only be instantiated on the main thread!'
*** First throw call stack:
(
)
libc++abi: terminating due to uncaught exception of type NSException

[45503] signal 6: Abort trap: 6
in expression starting at none:0
__pthread_kill at /usr/lib/system/libsystem_kernel.dylib (unknown line)
Allocations: 14353417 (Pool: 14352381; Big: 1036); GC: 17

That's at the start of the session, no code run before it. It's also sporadic - no guarantee if I will hit it or not.

@asinghvi17 asinghvi17 added bug GLMakie This relates to GLMakie.jl, the OpenGL backend for Makie. regression This issue describes a regression from a previous version or commit. macOS For issues involving macOS and the M-series processor labels Dec 22, 2024
@asinghvi17
Copy link
Member Author

asinghvi17 commented Dec 24, 2024

Hmm, this might be a thread juggling issue? I can reliably replicate this with:

using GLMakie
_task = Threads.@spawn begin
       display(Figure())
end
fetch(task)

so if the executing thread is not the "main" thread according to macOS, this might fail...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug GLMakie This relates to GLMakie.jl, the OpenGL backend for Makie. macOS For issues involving macOS and the M-series processor regression This issue describes a regression from a previous version or commit.
Projects
None yet
Development

No branches or pull requests

1 participant