Dan Kenigsberg has submitted this change and it was merged.
Change subject: Fix tokenizing of unsupported data in vdsmapi-schema.json
......................................................................
Fix tokenizing of unsupported data in vdsmapi-schema.json
vdsmapi tokenizer got into an endless loop when unsupported token was
found. Example input trigering this are invalid tokens such as unquoted
string, or valid JSON tokens like null, true and false, which are not
supported by the parser.
Now the tokenizer raise ValueError with the offending data. This should
be good enough for developers usage.
New unittests cover tokenizing valid, invalid and unspported tokens.
Change-Id: I7d29686d3189fd9e64e26c56dcd9da370f855406
Signed-off-by: Nir Soffer <nsoffer(a)redhat.com>
Reviewed-on:
http://gerrit.ovirt.org/19697
Reviewed-by: Allon Mureinik <amureini(a)redhat.com>
Reviewed-by: Saggi Mizrahi <smizrahi(a)redhat.com>
---
M tests/schemaTests.py
M vdsm_api/vdsmapi.py
2 files changed, 70 insertions(+), 0 deletions(-)
Approvals:
Nir Soffer: Verified
Saggi Mizrahi: Looks good to me, approved
Allon Mureinik: Looks good to me, but someone else must approve
--
To view, visit
http://gerrit.ovirt.org/19697
To unsubscribe, visit
http://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I7d29686d3189fd9e64e26c56dcd9da370f855406
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini(a)redhat.com>
Gerrit-Reviewer: Ayal Baron <abaron(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce(a)redhat.com>
Gerrit-Reviewer: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi(a)redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server