Save my hair! Add doc about "no module named <blah>"
|Reported by:||anonymous||Owned by:||Jacob|
|Has patch:||no||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
I spent the better part of half a day whacking against a "no module named apps.wiki" problem. Please, please, save the next guy's hair follicles.
I went into Python and did "import sys" and "print sys.path" and yep, the directory was on the path! But still, no joy. Finally after a long time I dimly remembered that the "init.py" file might be needed in "apps," and sure enough once I put the file there, "Joy!" But my poor scalp may never be the same. So, two quick docs-suggestions:
(1) Remind folks, at the appropriate time and place, about PYTHONPATH and maybe ".bashrc." Point them, of course, to a suitable existing page, e.g. at the Python site.
(2) Remind them specifically about this "amazingly obscure init.py thing," because Python's non-message is absolutely uninformative. I literally "solved" this problem by accident.
It is certainly very easy for people who work with a computer programming language every working day, to lose track of just how incomprehensibly frustrating an incomprehensible problem can be, and this is certainly one of those. I think it's safe to say that this is going to "bite" every single Django noobie ... and it also bit me, and I TOO work with Python every single workday. So, at the various places in the intro and the task-specific docs on the site where the user's likely to encounter this source of baldness, "just a few words, please."
Change History (7)
comment:3 Changed 10 years ago by
|Component:||Django Web site → Documentation|
|Status:||new → closed|