Showing content from http://mail.python.org/pipermail/python-dev/attachments/20060626/ce3bbfec/attachment-0001.obj below:
--- Python-2.5b1/Python/import.c 2006-05-28 14:57:35.000000000 -0700 +++ patched/Python/import.c 2006-06-26 03:20:11.000000000 -0700 @@ -21,6 +21,11 @@ extern "C" { #endif +static const char* PyImportError_No_module_named_hint = +" Note that subdirectories are searched for imports only if they contain an\n" +" __init__.py file. See the section on \"Packages\" in the Python tutorial for\n" +" details (http://www.python.org/doc/tut/)."; + extern time_t PyOS_GetLastModificationTime(char *, FILE *); /* In getmtime.c */ @@ -1410,7 +1415,8 @@ } if (fp == NULL) { PyErr_Format(PyExc_ImportError, - "No module named %.200s", name); + "No module named %.200s\n%s", name, + PyImportError_No_module_named_hint); return NULL; } *p_fp = fp; @@ -2214,7 +2220,8 @@ if (result == Py_None) { Py_DECREF(result); PyErr_Format(PyExc_ImportError, - "No module named %.200s", name); + "No module named %.200s\n%s", name, + PyImportError_No_module_named_hint); return NULL; }
RetroSearch is an open source project built by @garambo
| Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4