-
Notifications
You must be signed in to change notification settings - Fork 7
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
Simpler soft erroring during load #63
Simpler soft erroring during load #63
Conversation
What kind of errors? Another thought - why don't we just look the library up at init time and do away with the build file altogether? It doesn't actually do much and it makes package stateful which is frowned upon in the new world. |
Yeah.. why not.. It's not like there's huge overhead in finding the lib. I was seeing situations where the deps.jl file is created successfully, but the precompiled package was claiming it wasn't. The state of |
I think the only reason that it was like this in the beginning was to ensure that the library was present at build time. Once that was circumvented there was no need for there to be any build step. So we check for and attempt to load the library during init. If it doesn't load the reference to the library remains Do you know if |
Refactored to just check dlopen during init. Works nicely in the case where the lib is present.
Unfortunately though, it seems we might have a problem on 1.4.0 (above was 1.3.1)
|
The 1.4.0 bug seems to be two things..
Thanks to @staticfloat for figuring all this out! |
Okay so this still has a build step or searching for the libraries, is that required? What does it do? Are the above fixes sufficient to make this work on MacOS? |
Apologies, the revert to the build method was an error during debugging.
I'm 99% sure.. I haven't reverted my system to a clean install and re-tested |
I can do this on 1.3 if you can hold on till tomorrow? |
Absolutely |
Works fine on virgin environment, 1.3. It would probably be better if we just have const global ref to the library, and we assign at init, rather than this convoluted baking in of the path at recompilation. But I appreciate it is more work and not critical. I will update the README, are the two fixes above still required, and only on MacOS? |
That doesn’t work. The path to the library is to be a proper const. I tried that initially and ccall complained. There’s a few issues out there about it |
How bizarre. and how about the fixes above, are they required on MacOS only on 1.4 only? |
Yes but likely even more specific to the macOS 1.4 notarized official binary. |
Hmm that was an accident but it's good to go isn't it? |
Yeah 👍🏻 |
Okay good. I got a bit trigger happy on the command line. New version registration in progress. |
I've been seeing odd loading instabilities that might be due to the way the soft erroring was designed.
This is a bit simpler, and my problems went away when I did it.. Although, I'm not certain that this specifically was the fix.