You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@daffodil.apache.org by "Mike Beckerle (Jira)" <ji...@apache.org> on 2021/01/20 01:15:00 UTC
[jira] [Created] (DAFFODIL-2456) No way to get infoset result from
parse, while outputing validation errors
Mike Beckerle created DAFFODIL-2456:
---------------------------------------
Summary: No way to get infoset result from parse, while outputing validation errors
Key: DAFFODIL-2456
URL: https://issues.apache.org/jira/browse/DAFFODIL-2456
Project: Daffodil
Issue Type: Bug
Components: API
Affects Versions: 3.0.0
Reporter: Mike Beckerle
Fix For: 3.1.0
In JAPI, there is no way to parse, get a result back, but also get validation errors back.
Validation errors come through as diagnostics with isError true.
Calling outputter.getResult() requires that isError is false.
This prevents using validation errors like warnings.
I want to accept "well formed" but "invalid" data, and skip past it to the next input message.
I can't do that with the API like this.
I think I need getResult() to succeed if the errors are only validation errors (or recoverable errors), and give me the infoset.
We should also add a Diagnostic.isValidationError so that I can tell that a diagnostic is not a fatal error easily (currently one must call d.getMessage().contains("Validation Error") which is not a good API.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)