Invalidate importer caches when adding an import hook.