On Mon, 2007-04-23 at 16:45 -0400, Jason McVetta wrote:
> On 4/21/07, Ramashish Baranwal <[EMAIL PROTECTED]> wrote:
>           TypeError: Cannot resolve keyword 'book' into field
> 
> 
> This is a long-standing, well-known bug that apparently no one
> (including me) knows how to fix.  

Actually we do understand almost all the reasons. Particularly after
Øyvind's latest big discovery. See ticket #1796.

I now have to sit down and work out a proper solution. That will take
time and I don't have that at the moment because I have other
priorities. Of course, anybody else should feel free to dive in and
write a fix, too, but that hasn't happened so far.

Until then, anybody being bitten by the problem might want to try Ben
Slavin's workaround patch in #1796.

> Any time one defines a ManyToMany relationship, then calls all() on
> that relationship from a script, a "cannot resolve keyword into field"
> error results.  The problem involves some deep voodoo about how and
> when modules are imported, which is why it occurs only in scripts but
> not in the admin interface or the manage.py shell.

This is a bit of an oversimplification, since it occurs more with
reverse relationships and it's not "any time", it's only sometimes and
depends on the code (model names, etc), OS, installation details and
which deployment method you're running under. Typically the reverse to
what you describe occurs: a problem like this is more likely to show up
in the admin interface or when running under mod_python.



--~--~---------~--~----~------------~-------~--~----~
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