python_exc.PyErr_NoMemory is used because it does't try to allocate more memory (whereas rais MemoryError does)