mirror of
https://github.com/python/cpython.git
synced 2026-05-07 13:10:37 -04:00
GH-65961: Stop setting __cached__ on modules (GH-142165)
This commit is contained in:
@@ -478,9 +478,6 @@ _PyRun_SimpleFileObject(FILE *fp, PyObject *filename, int closeit,
|
||||
if (PyDict_SetItemString(dict, "__file__", filename) < 0) {
|
||||
goto done;
|
||||
}
|
||||
if (PyDict_SetItemString(dict, "__cached__", Py_None) < 0) {
|
||||
goto done;
|
||||
}
|
||||
set_file_name = 1;
|
||||
}
|
||||
|
||||
@@ -535,9 +532,6 @@ _PyRun_SimpleFileObject(FILE *fp, PyObject *filename, int closeit,
|
||||
if (PyDict_PopString(dict, "__file__", NULL) < 0) {
|
||||
PyErr_Print();
|
||||
}
|
||||
if (PyDict_PopString(dict, "__cached__", NULL) < 0) {
|
||||
PyErr_Print();
|
||||
}
|
||||
}
|
||||
Py_XDECREF(main_module);
|
||||
return ret;
|
||||
|
||||
Reference in New Issue
Block a user