Message262375
I will reply to my own question: in fact, ImportError is more convenient. The "try/except ImportError" pattern is common, in some cases, it's acceptable to skip a whole module. For a direct example on import during Python shutdown, see the issue #21925: "ResourceWarning sometimes doesn't display" which adds "try/except ImportError" to be able to log warnings.
@Brett, Eric: So, do you like importlib_shutdown-2.patch? |
|
Date |
User |
Action |
Args |
2016-03-24 20:49:08 | vstinner | set | recipients:
+ vstinner, brett.cannon, eric.snow |
2016-03-24 20:49:08 | vstinner | set | messageid: <1458852548.65.0.231303030909.issue26637@psf.upfronthosting.co.za> |
2016-03-24 20:49:08 | vstinner | link | issue26637 messages |
2016-03-24 20:49:08 | vstinner | create | |
|