Date field rise an error if Set Only Once is enabled and doc trying to be saved multiple time

Hi there,

i’ve set few field with Set Only Once set to 1; one of this field is a Date type named Data. See pic:

When i try save multiple times, an error is raised: Value cannot be changed for Data.

That’s the only field raising the error; it’s kind of strange because field is read only and Date value is not changed …

what i’m doing wrong?

Thx in advance

1 Like

Do you have any script that is trying to modify the date value?

Nope …no custom script

@Pawan could be the validator checking date and time instead of date only?

Any news on this? is that a bug?

@Pawan could u please have a look at:

it seems to be failing testing dates even if date are the equals; i have it working by changing to:

if self.get(fieldname) != str(values.get(fieldname)):

Actually i’m not sure if it work for every types …btw can you please have a look?

Edit: opened an issue on github:

https://github.com/frappe/frappe/issues/2224