frappe / press

Full service cloud hosting for the Frappe stack - powers Frappe Cloud
https://frappe.cloud
GNU Affero General Public License v3.0
270 stars 191 forks source link

Don't allow duplicate keys in config editor #1485

Open ankush opened 8 months ago

ankush commented 8 months ago

JSON doesn't support duplicate keys

image

ankush commented 8 months ago

@BreadGenie :eyes:

BreadGenie commented 8 months ago

This doesn't seem to be set from UI since we have a validation over there (In d2 it'll simply overwrite existing value) https://github.com/frappe/press/blob/78153fbcfe2e024542d56d7a50f3385b36ecf3e3/dashboard/src/components/ConfigEditor.vue#L189-L191

It looks like it's coming from a job 🤔 I'll add a validation in backend as well

BreadGenie commented 5 months ago

closing since old dashboard

ankush commented 5 months ago

@BreadGenie it is server side that's supposed to validate this. It was duplicated due to some other bug but if there was a validation in place it would've been caught sooner.

ankush commented 5 months ago

Would suggest reopening if we still allow duplicate keys in that table.