PyAPI: Replace importlib.reload, not 'imp'
authorCampbell Barton <ideasman42@gmail.com>
Fri, 23 Jan 2015 05:34:08 +0000 (16:34 +1100)
committerCampbell Barton <ideasman42@gmail.com>
Fri, 23 Jan 2015 05:37:30 +0000 (16:37 +1100)
source/blender/python/generic/bpy_internal_import.c

index b053960..ed2752d 100644 (file)
@@ -81,7 +81,7 @@ void bpy_import_init(PyObject *builtins)
 
        /* move reload here
         * XXX, use import hooks */
-       mod = PyImport_ImportModuleLevel("imp", NULL, NULL, NULL, 0);
+       mod = PyImport_ImportModuleLevel("importlib", NULL, NULL, NULL, 0);
        if (mod) {
                PyObject *mod_dict = PyModule_GetDict(mod);
 
@@ -93,7 +93,7 @@ void bpy_import_init(PyObject *builtins)
                Py_DECREF(mod);
        }
        else {
-               BLI_assert(!"unable to load 'imp' module.");
+               BLI_assert(!"unable to load 'importlib' module.");
        }
 }