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

Include ccall :jl_generating_output in try block #8

Merged
merged 1 commit into from
May 2, 2022

Conversation

fonsp
Copy link
Collaborator

@fonsp fonsp commented May 2, 2022

This guards against the situation where :jl_generating_output is removed in a future release

julia> ccall(:jl_asdfasdfasdf, Cint, ())
ERROR: could not load symbol "jl_asdfasdfasdf":
dlsym(RTLD_DEFAULT, jl_asdfasdfasdf): symbol not found
Stacktrace:
 [1] top-level scope
   @ ./REPL[1]:1

julia> try
           ccall(:jl_asdfasdfasdf, Cint, ())
       catch
           0
       end
0

@rikhuijzer
Copy link
Owner

This guards against the situation where :jl_generating_output is removed in a future release

julia> ccall(:jl_asdfasdfasdf, Cint, ())
ERROR: could not load symbol "jl_asdfasdfasdf":
dlsym(RTLD_DEFAULT, jl_asdfasdfasdf): symbol not found
Stacktrace:
 [1] top-level scope
   @ ./REPL[1]:1

julia> try
           ccall(:jl_asdfasdfasdf, Cint, ())
       catch
           0
       end
0

Ah this is of course for your goal of ensuring that Pluto can always reproduce stuff. Nice! I'll merge and register a new version as soon as the tests pass.

@rikhuijzer rikhuijzer enabled auto-merge (squash) May 2, 2022 12:45
@rikhuijzer rikhuijzer merged commit 3a56550 into rikhuijzer:main May 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants