#22930: AttributeError: 'module' object has no attribute 'models' when debug =
false
--------------------------------+---------------------------------------
     Reporter:  alan@…          |                    Owner:  Alan Campos
         Type:  Uncategorized   |                   Status:  closed
    Component:  Uncategorized   |                  Version:  1.4
     Severity:  Normal          |               Resolution:  duplicate
     Keywords:  AttributeError  |             Triage Stage:  Unreviewed
    Has patch:  0               |      Needs documentation:  0
  Needs tests:  0               |  Patch needs improvement:  0
Easy pickings:  0               |                    UI/UX:  0
--------------------------------+---------------------------------------
Changes (by timo):

 * status:  new => closed
 * needs_better_patch:   => 0
 * needs_tests:   => 0
 * needs_docs:   => 0
 * resolution:   => duplicate


Old description:

> When I set variable Debug to False in django==1.4.5, the server throws me
> a 500 error. I don't know what I'm doing wrong. I f I  set to True it
> doesn't have any problem.  My allowed hosts is like this
> ALLOWED_HOSTS = [
>     'domain name',
>     'ip-address', # Allow domain and subdomains
> ]
>
> My apache configuration is like this:
> <VirtualHost *:80>
>     WSGIDaemonProcess Vermonti python-
> path=/srv/www/app:/srv/www/app/ENV/lib/python2.7/site-packages
>     WSGIProcessGroup app
>     WSGIScriptAlias / /srv/www/Vermonti/app/wsgi.py
>     ServerName domain name
>     DocumentRoot /srv/www/app
>
>     <Directory /srv/www/app>
>         Order allow,deny
>         Allow from all
>     </Directory>
>     SetEnv DJANGO_SETTINGS_MODULE app.settings
> </VirtualHost>

New description:

 When I set variable Debug to False in django==1.4.5, the server throws me
 a 500 error. I don't know what I'm doing wrong. I f I  set to True it
 doesn't have any problem.  My allowed hosts is like this
 {{{
 ALLOWED_HOSTS = [
     'domain name',
     'ip-address', # Allow domain and subdomains
 ]
 }}}

 My apache configuration is like this:
 {{{
 <VirtualHost *:80>
     WSGIDaemonProcess Vermonti python-
 path=/srv/www/app:/srv/www/app/ENV/lib/python2.7/site-packages
     WSGIProcessGroup app
     WSGIScriptAlias / /srv/www/Vermonti/app/wsgi.py
     ServerName domain name
     DocumentRoot /srv/www/app

     <Directory /srv/www/app>
         Order allow,deny
         Allow from all
     </Directory>
     SetEnv DJANGO_SETTINGS_MODULE app.settings
 </VirtualHost>
 }}}

--

Comment:

 I suspect this is some loading issue similar to #10405. It's probably
 fixed in 1.7 by the app loading refactor. Please reopen if you can test
 there and it's still an issue, although I think it's more likely you
 should use TicketClosingReasons/UseSupportChannels to get help.

 Also, note that 1.4.5 has known security issues and you should upgrade to
 the latest minor release (1.4.13 as of this writing) ASAP.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/22930#comment:1>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/076.cfbbca53df133cad5639dc8614f8dd7b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to