Error was: No module named Random
Python 2.4.3, when I run python via the command line and import random, it works just fine. When I run a django based website "python manage.py runserver", the server starts up fine, but as soon as I load a page, it tosses me this error.
I really have no clue how to fix this. I've done some searching, random is core to python, the import I tried from the pyth开发者_如何学Goon interpreter seems to indicated to me that it's working. However, it's not working when running the website.
Any help would be greatly appreciated,
Thanks, ~P
If the error is exactly "No module named Random", then you've written import Random
when you really meant import random
. There is no module in the Python standard library called Random
. Module names are case sensitive in Python. If that doesn't solve your problem, please show us some code from whatever module imports random
精彩评论