Suppressing conditional errors
Post here questions and problems related to editing and publishing DITA content.
-
- Posts: 54
- Joined: Mon Jun 27, 2011 10:51 pm
Suppressing conditional errors
I get the following error during transformation
There's an understandable if annoying reason for the toolkit to throw the error: the variable it's complaining about is conditional and was excluded in this particular transform scenario.
Problem I'm trying to solve is how to suppress this specific error so that I can more easily see other unexpected errors. Because of where this variable exists, these error messages pollute my logs, making it really difficult to find the unexpected.
This has been a long-standing nit in DITA conditional processing: it throws an error about not being able to find an element that was deliberately excluded.
Any workaround for this nit is very welcome.
Code: Select all
[DOTX010E][ERROR]: Unable to find target for conref="#variables/llAirgap".
Problem I'm trying to solve is how to suppress this specific error so that I can more easily see other unexpected errors. Because of where this variable exists, these error messages pollute my logs, making it really difficult to find the unexpected.
This has been a long-standing nit in DITA conditional processing: it throws an error about not being able to find an element that was deliberately excluded.
Any workaround for this nit is very welcome.
-
- Posts: 9446
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Suppressing conditional errors
Hi,
Can you give me more details about how the actual DITA code looks like?
Do you have something like:
and you exclude "novice" audience using the filter, but still obtain the problem?
Or do you exclude only the target of the conref but not the source of the conref?
Regards,
Radu
Can you give me more details about how the actual DITA code looks like?
Do you have something like:
Code: Select all
<ph conref="..." audience="novice"/>
Or do you exclude only the target of the conref but not the source of the conref?
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 54
- Joined: Mon Jun 27, 2011 10:51 pm
Re: Suppressing conditional errors
Fairly certain my scenario is like your first example. I've a variables.dita file with this entry:
Other entries embed the above, for example:
The ditaval for the transform says:
Code: Select all
<ph id="llAirgap" props="AirGap">Air Gap </ph>
Code: Select all
<ph id="llAnalyst"><ph conref="#variables/llAirgap"/>Analyst</ph>
Code: Select all
<prop action="exclude" att="props" val="AirGap"/>
-
- Posts: 9446
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Suppressing conditional errors
Hi,
If you want to avoid seeing the error the filter attribute should go also on the attribute which has the conref:
otherwise when the target element is filtered out, the conref can no longer be resolved and thus the error is reported. The error should not be a fatal one.
A trick might be to do this:
in order to avoid removing the entire target element, but remove only its contents.
Regards,
Radu
If you want to avoid seeing the error the filter attribute should go also on the attribute which has the conref:
Code: Select all
<ph conref="#variables/llAirgap" props="AirGap"/>
A trick might be to do this:
Code: Select all
<ph id="llAirgap"><ph props="AirGap">Air Gap </ph></ph>
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Return to “DITA (Editing and Publishing DITA Content)”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ Artificial Intelligence (AI Positron Assistant add-on)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service