Author Oren Milman
Recipients Oren Milman
Date 2017-08-31.16:25:55
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1504196755.68.0.337811894425.issue31315@psf.upfronthosting.co.za>
In-reply-to
Content
The following code causes an assertion failure in get_encoded_name(), which is
called by _PyImport_LoadDynamicModuleWithSpec() (in Python/importdl.c):

import imp

class BadSpec:
    name = 42
    origin = 'foo'

imp.create_dynamic(BadSpec())


this is because _PyImport_LoadDynamicModuleWithSpec() assumes that spec.name is
a string.


should we fix this (even though imp is deprecated)?
History
Date User Action Args
2017-08-31 16:25:55Oren Milmansetrecipients: + Oren Milman
2017-08-31 16:25:55Oren Milmansetmessageid: <1504196755.68.0.337811894425.issue31315@psf.upfronthosting.co.za>
2017-08-31 16:25:55Oren Milmanlinkissue31315 messages
2017-08-31 16:25:55Oren Milmancreate