Ivan Sagalaev wrote:
[...]
> fabio natali wrote:
> > KeyError at /manufacturer
> > u'manufacturer'
> > when accessing http://localhost:8000/manufacturer
> 
> KeyError says that it can't find a key 'manufacturer' in dict 
> model_classes. This leads me to think that model_classes is empty. It 
> can be because my example is creating it by listing you module "models":
> 
>      ... for i in dir(models) ...
> 
> and I don't see where this "models" is imported. I was a bit sloppy when 
> I was writing it and have it omitted. So you should import it. It's simply
> 
>      import models

I added the line

      import arteak.management.models

(and also tried a few alternatives) but I still get the same error. If
it may come of help I also get a

TypeError at /
'str' object is not callable

when accessing http://localhost:8000/ (that is the main page).

Here comes my current urls.py: http://dpaste.com/72623/

Anyway I don't want to steal your time any longer. I really hoped
saving some lines in urls.py could be easier. I'd probably better to
write a short bash script to generate a urls.py file from my models.py
with all the proper generic views entries for each model.

Thank you very much, Fabio.

-- 
Fabio Natali

--~--~---------~--~----~------------~-------~--~----~
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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to