Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6824183
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T21:52:17+00:00 2026-05-26T21:52:17+00:00

I got a Django project, with 1 application in it. If I have debug

  • 0

I got a Django project, with 1 application in it.

If I have debug set to True, and I hit write in a url like /sdfsdfsf then it will give an error

Using the URLconf defined in website.urls, Django tried these URL patterns, in this order:
...
The current URL, dsd, didn't match any of these.
You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard 404 page.

I then edit the settings.py to turn off Debug, but now I get 500 error. I look in the error config and get this;

mod_wsgi (pid=17601): Exception occurred processing WSGI script '/var/websites/xxxxx/website/django.wsgi'.
Traceback (most recent call last):
    File "/usr/local/lib/python2.6/dist-packages/django/core/handlers/wsgi.py", line 272, in __call__
        response = self.get_response(request)
    File "/usr/local/lib/python2.6/dist-packages/django/core/handlers/base.py", line 153, in get_response
        response = self.handle_uncaught_exception(request, resolver, sys.exc_info())
    File "/usr/local/lib/python2.6/dist-packages/django/core/handlers/base.py", line 218, in handle_uncaught_exception
        return callback(request, **param_dict)
    File "/usr/local/lib/python2.6/dist-packages/django/utils/decorators.py", line 93, in _wrapped_view
        response = view_func(request, *args, **kwargs)
    File "/usr/local/lib/python2.6/dist-packages/django/views/defaults.py", line 30, in server_error
        t = loader.get_template(template_name) # You need to create a 500.html template.
    File "/usr/local/lib/python2.6/dist-packages/django/template/loader.py", line 157, in get_template
        template, origin = find_template(template_name)
    File "/usr/local/lib/python2.6/dist-packages/django/template/loader.py", line 128, in find_template
        loader = find_template_loader(loader_name)
    File "/usr/local/lib/python2.6/dist-packages/django/template/loader.py", line 95, in find_template_loader
        mod = import_module(module)
    File "/usr/local/lib/python2.6/dist-packages/django/utils/importlib.py", line 35, in import_module
        __import__(name)
    File "/usr/local/lib/python2.6/dist-packages/django/template/loaders/app_directories.py", line 23, in <module>
        raise ImproperlyConfigured('ImportError %s: %s' % (app, e.args[0]))
    ImproperlyConfigured: ImportError cardir: No module named cardir

cardir is the name of my app in the project. However if go to a page which is not a 404 (like / or /about) the it works fine, so it can get the cardir. I feel something else is going on.

Structure;

# ls
cardir  django.wsgi  __init__.py  __init__.pyc  manage.py  settings.py  settings.pyc  static  templates  urls.py  urls.pyc

# cd templates/ && ls
404.html  500.html  base.html  index.html
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T21:52:18+00:00Added an answer on May 26, 2026 at 9:52 pm

    Check if there is not an error in 404.html. I had similar issue some time ago.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have built my website in Django. And like any other django project I
I've got a django project working on a development server(ubuntu) that we have been
I've got these models in my Django project: class Area(models.Model): name = models.CharField(max_length=100, primary_key=True)
I've got my Django project running well, and a separate background process which will
I've got a django project that contain some apps. The main urls.py includes the
I’ve got a brand new Django project. I’ve added one minimal view function to
I've got a couple django models that look like this: from django.contrib.sites.models import Site
Given that django-nonrel has got JOINs working, does this mean we have M2M fields
So basically, I've got a rather large Django project going. It's a private web
So I have installed Django on my FreeBSD 8.2 box like this: pip install

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.