Closed sfc-gh-aling closed 6 months ago
As mentioned in Slack: One thing to keep in mind is that atexit
handlers don't get run if os._exit()
is called or the process crashes.
thanks @sfc-gh-bwarsaw , this should not be a concern to our connector as we didn't perform critical job during the closing stage.
Please answer these questions before submitting your pull requests. Thanks!
What GitHub issue is this PR addressing? Make sure that there is an accompanying issue to your PR.
the
__del__
method is unstable and gets called at random timing. in one of the recent report, we found the__del__
is causing circular import issue.as a short term fix, we fix by moving away from
__del__
method to usingatexit
to clean up connection at intepreter shutdown time.long term fix plan here: SNOW-1218851
Fill out the following pre-review checklist:
Please describe how your code solves the related issue.
Please write a short description of how your code change solves the related issue.