[
https://issues.apache.org/jira/browse/DAFFODIL-2953?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17895450#comment-17895450
]
Olabusayo Kilo edited comment on DAFFODIL-2953 at 11/4/24 11:02 PM:
--------------------------------------------------------------------
The error is actually from our DaffodilXMLLoader code. Looks like we pass in a
null locator to the SAXParseExceptions in this file, because Xerces doesn't
report an error where it doesn't resolve. Not sure how we can get the line and
column number without doing some weird stuff with reading the lines of file in
$systemId, then finding the line number by searching for where we match on
schemaLocation=$uri, then searching that line to get the exact column number.
was (Author: [email protected]):
The error is actually from our DaffodilXMLLoader code. Looks like we pass in a
null locator to the SAXParseExceptions in this file, because Xerces doesn't
report an error where it doesn't resolve. Not sure how we can get the line and
column number without doing some weird stuff with reading the lines of the
file, then finding the line number by searching for where we match on
schemaLocation=$systemId, then searching that line to get the exact column
number.
> "Unable to resolve schemaLocation" error fails to give line/column number
> information
> -------------------------------------------------------------------------------------
>
> Key: DAFFODIL-2953
> URL: https://issues.apache.org/jira/browse/DAFFODIL-2953
> Project: Daffodil
> Issue Type: Bug
> Components: Front End
> Reporter: Steve Lawrence
> Priority: Major
>
> If I have something like this in a schema:
> {code:xml}
> <xs:import ... schemaLocation="/does/not/exists.dfdl.xsd" />
> {code}
> Then I get an error like this:
> {quote}
> [error] Schema Definition Error: Error loading schema due to Unable to
> resolve schemaLocation: /does/not/exists.dfdl.xsd
> Schema context: Location line -1 column -1 in src/main.dfdl.xsd
> {quote}
> Looks like this error message is from Xerces.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)