• Brett Cannon's avatar
    Issue #17358: imp.load_source() and load_compiled() should now return · 5a4c233a
    Brett Cannon authored
    modules which will typically work when reloaded.
    
    A hack is used to support these functions as their API allowed them to
    pass in a file object but then operate as if import had loaded them.
    Unfortunately the hack kept a reference around for the file object
    passed in which would be unusable on reload since it had been closed.
    The solution is to simply use the hack for the initial load but then a
    proper loader on the module so that imp.reload() at least has a chance
    to work.
    5a4c233a
NEWS 202 KB