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

.onUnload() is no longer called #253

Open
hadley opened this issue Jul 25, 2023 · 2 comments
Open

.onUnload() is no longer called #253

hadley opened this issue Jul 25, 2023 · 2 comments

Comments

@hadley
Copy link
Member

hadley commented Jul 25, 2023

Probably because of the changes in 2d28e26 where we no longer call unloadNamespace(). So now we should call .onUnload() if present, and similarly handle the onUnload hook.

@lionel-
Copy link
Member

lionel- commented Sep 20, 2023

hmm, one problem I can see with this is that we try to preserve stale namespaces in a working state since it's so easy to run into dangling references, for example via an imports env populated before a load_all() call.

So it depends on what conventions should apply to the unload hook. Is it UB to call into a namespace that has run this hook, or should the package gracefully handle this situation?

@DavisVaughan
Copy link
Member

Not calling .onUnload() was intentional according to #148 (comment)

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

No branches or pull requests

3 participants