-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
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
Regression between 0.8.1 and 0.8.2 #381
Comments
I believe this is a result of #342, setting to None now resets to the On Sunday, June 23, 2013, Mitar wrote:
|
Ehm. No, I want it to set to So, Django does not reset to default when you set to |
Sorry, ignore the previous comment: should have been #349. |
This was an unintended regression between 0.7 and 0.8 branches. Possible fix: Define in the fields how they handle |
Marking to fix in 0.9 - sorry it wasn't intended for the 0.8 branch to change. But I agree I think it is bad. |
Yes, one way would be that fields should allow easy way to specify what should be Maybe it would be easier to define MongoEngine specific constant value DEFAULT_VALUE. And if you assign that value to the field, field gets assigned a constant value? If you assign Still, if you want, you could allow fields to override this, but this should be the default in my opinion. |
Hello, Thanks ! |
Any progress on this? |
Does #734 solves your problem? (PR will soon be merged in) |
Where is the pull request? |
It should have fixed it. Try with 0.9+ If not, please reopen |
In my tests I found a regression between 0.8.1 and 0.8.2. I have such model:
And in 0.8.1 if I create a new
BlankableParent
object it gets a default value forembedded
. But if I then setembedded
toNone
and try to save it, I get an error. Which is what I expect.In 0.8.2 when I set
embedded
to None it is just reset back to default value. Which is strange. And at least not something which happens in Django.The text was updated successfully, but these errors were encountered: