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 stefan
Recipients stefan
Date 2020-04-10.22:33:48
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
I'm trying to import custom scripts that expect the presence of certain variables in the global namespace.
It seems `__import__('script', globals=dict(foo='bar'))` doesn't have the expected effect of injecting "foo" into the namespace and making it accessible to the script being loaded.

Is this a bug in `__import__` or am I missing something ? If the behaviour is expected, how can I achieve the desired behaviour ?
Date User Action Args
2020-04-10 22:33:48stefansetrecipients: + stefan
2020-04-10 22:33:48stefansetmessageid: <>
2020-04-10 22:33:48stefanlinkissue40249 messages
2020-04-10 22:33:48stefancreate