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 dino.viehland
Recipients dino.viehland
Date 2020-02-04.20:27:49
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
The fix for bpo-17636 added support for falling back to sys.modules when a module isn't directly present on the module.  But mock doesn't have the same behavior - it'll try the import, and then try to get the value off the object.  If it's not there it just errors out.

Instead it should also consult sys.modules to be consistent with import semantics.
Date User Action Args
2020-02-04 20:27:49dino.viehlandsetrecipients: + dino.viehland
2020-02-04 20:27:49dino.viehlandsetmessageid: <>
2020-02-04 20:27:49dino.viehlandlinkissue39551 messages
2020-02-04 20:27:49dino.viehlandcreate