This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author christian.heimes
Recipients christian.heimes, gvanrossum
Date 2007-12-07.13:24:03
SpamBayes Score 0.00054840813
Marked as misclassified No
Message-id <1197033844.22.0.578664150346.issue1567@psf.upfronthosting.co.za>
In-reply-to
Content
The patch adds a new API method _PyImport_ImportModuleNoLock(const char
*name). It works mostly like PyImport_ImportModule except it does not
block. It tries to fetch the module from sys.modules first and falls
back to PyImport_ImportModule UNLESS the import lock is held by another
thread.

It fixes several issues related to dead locks when a thread uses a
function that imports a module but another thread holds the lock. It
doesn't require static caching of modules.

The patch is against py3k but I can backport it to 2.6.
Files
File name Uploaded
import_nolock.diff christian.heimes, 2007-12-07.13:24:03
History
Date User Action Args
2007-12-07 13:24:04christian.heimessetspambayes_score: 0.000548408 -> 0.00054840813
recipients: + christian.heimes, gvanrossum
2007-12-07 13:24:04christian.heimessetspambayes_score: 0.000548408 -> 0.000548408
messageid: <1197033844.22.0.578664150346.issue1567@psf.upfronthosting.co.za>
2007-12-07 13:24:04christian.heimeslinkissue1567 messages
2007-12-07 13:24:03christian.heimescreate