odoo/o-spreadsheet#4832

Created by fw-bot
Merged at ee5ba9270f45525f4439c54f297a0631f461a18e

Statuses:

label
odoo:saas-17.4-15.0-parse-empty-string-lul-JFtm-fw
head
5dde2684b4ec65029960be3dc8fef734d784443d
merged
9 months ago by BI, Lucas Lefèvre (lul)
odoo/o-spreadsheet
15.0 #4825
16.0 #4826
17.0 #4827
saas-17.4 #4832
saas-17.1 #4829
saas-17.2 #4830
18.0
saas-18.1
saas-18.2
saas-18.3
master #4833

[FW][FIX] parser: parsing empty string throws meaningful error

Description:

parse("") throws an error like cannot ready property of undefined.

Note that it doesn't cause any (known) real bug, but let's make it more robust nonetheless.

With this commit, it throws a user friendly message.

Task: : TASK_ID

review checklist

  • [ ] feature is organized in plugin, or UI components
  • [ ] support of duplicate sheet (deep copy)
  • [ ] in model/core: ranges are Range object, and can be adapted (adaptRanges)
  • [ ] in model/UI: ranges are strings (to show the user)
  • [ ] undo-able commands (uses this.history.update)
  • [ ] multiuser-able commands (has inverse commands and transformations where needed)
  • [ ] new/updated/removed commands are documented
  • [ ] exportable in excel
  • [ ] translations (_t("qmsdf %s", abc))
  • [ ] unit tested
  • [ ] clean commented code
  • [ ] track breaking changes
  • [ ] doc is rebuild (npm run doc)
  • [ ] status is correct in Odoo

Forward-Port-Of: #4827
Forward-Port-Of: #4825