We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Possibly a django 1.4 problem.
E.g.
class Animal(TypeModel): owner = models.ForeignKey(Owner, related_name="animals") name = models.CharField(max_length=40) class Cat(Animal): def speak(self): return "Meow" class Dog(Animal): def speak(self): return "Woof" cat = Cat(owner=owner, name='Fluffy') cat.save() # missing owner violates key constraints
But constructing with the superclass works:
cat = Animal(type='app.cat', owner=owner. name='Fluffy') cat.save() # worked
Seems to be that the class _meta.fields list contains duplicates, so the first time values are popped from kwargs, then removed on the second pass.
_meta.fields
kwargs
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Possibly a django 1.4 problem.
E.g.
But constructing with the superclass works:
Seems to be that the class
_meta.fields
list contains duplicates, so the first time values are popped fromkwargs
, then removed on the second pass.The text was updated successfully, but these errors were encountered: