mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-05-30 13:18:56 -06:00
bugfix
This commit is contained in:
@@ -401,7 +401,7 @@ PGF_embed(PGFObject* self, PyObject *modname)
|
|||||||
{
|
{
|
||||||
PyObject *m = PyImport_Import(modname);
|
PyObject *m = PyImport_Import(modname);
|
||||||
if (m == NULL) {
|
if (m == NULL) {
|
||||||
PyObject *globals = PyEval_GetGlobals();
|
PyObject *globals = PyEval_GetBuiltins();
|
||||||
if (globals != NULL) {
|
if (globals != NULL) {
|
||||||
PyObject *exc = PyDict_GetItemString(globals, "ModuleNotFoundError");
|
PyObject *exc = PyDict_GetItemString(globals, "ModuleNotFoundError");
|
||||||
if (exc != NULL) {
|
if (exc != NULL) {
|
||||||
|
|||||||
Reference in New Issue
Block a user