hi,
I have an old site running on revision 2486 - had not touched it for years and 
since it wasnt broken nor needed new features, I did not upgrade it. A new 
model was required, so I added it, but it was not appearing in sqlall 
statement. The application is called 'web' and under the directory 'web' 
there are 2 files 'models.py' and 'views.py'. The new model was 
called 'Affiliation', and the site started barfing saying 'cannot import 
affiliations'. I then noticed that views.py had a statement:

from myapp.web.models.web import *

there is a directory called myapp.web.models, but that only held an 
__init__.py file which was empty. In those days django required for models in 
an app called web, to have a directory like
web/models/web.py and /web/views/web.py. Apparently some years back I had 
changed this to the current directory structure as web/views.py and 
web/models.py. But I could not understand how the site was working until I 
saw on the production server a file called ~/models/web.pyc. The site had 
been using this all these years which is why my new model was not noticed. I 
restored the old directory structure - the site load fine now. But - in 
admin, the only things that show up are are auth and core - no sign of 'web'. 
Any clues (I know I should not expect people to help out on such old stuff, 
but if there *are* any oldtimers with long memories ...)
-- 
regards
KG
http://lawgon.livejournal.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to