views:

1433

answers:

1

I am trying to debug my application with Pydev 1.5

I have done almost everything that's mentioned in the docs to start the debugger.

I get this error when I try to start the debugging:

pydev debugger: warning: psyco not available for speedups (the debugger will still work correctly, but a bit slower)
pydev debugger: starting
Traceback (most recent call last):
  File "C:\Documents and Settings\mkallat\Desktop\eclipse\plugins\org.python.pydev.debug_1.5.0.1251989166\pysrc\pydevd.py", line 953, in <module>
    debugger.run(setup['file'], None, None)
  File "C:\Documents and Settings\mkallat\Desktop\eclipse\plugins\org.python.pydev.debug_1.5.0.1251989166\pysrc\pydevd.py", line 780, in run
    execfile(file, globals, locals) #execute the script
  File "Z:\dev\hfholidays\urls.py", line 1, in <module>
    from django.conf.urls.defaults import *
ImportError: No module named django.conf.urls.defaults

Please suggest me what's the best solution to this. Or am I missing something?

Thanks in advance.

+4  A: 

You are missing django - pydev cannot find the django modules

You need to have all the python modules you need accessible to python this is usually done by having the environment variable PYTHONPATH include the directory of the module.

In pydev go to project->Properties->Pydev-PYTHONPATH choose the External libraries tab. You need to add the django package to your path.

Alternatively the normal Djano install should have put django into python's site-packages and so should be available on PYTHONPATH

Mark