Unable to import xliff 1.2 file (Index was out of range)

Hello all,

We're experiencing difficulties importing xliff 1.2 files we have received (Studio is unable to convert to translable format).

We receive the following error message: 

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<SDLErrorDetails time="22/12/2022 18:15:21">
<ErrorMessage>Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index</ErrorMessage>
<Exception>
<Type>System.ArgumentOutOfRangeException, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</Type>
<ParamName>index</ParamName>
<HelpLink />
<Source>mscorlib</Source>
<HResult>-2146233086</HResult>
<StackTrace><![CDATA[ at System.ThrowHelper.ThrowArgumentOutOfRangeException(ExceptionArgument argument, ExceptionResource resource)
at Sdl.FileTypeSupport.Filters.Xliff.Infrastructure.ParagraphUnitBuilder.HasElementsBetweenSegments(Int32 previousSegmentPosition, Int32 currentSegmentIndex, List`1 paragraph)
at Sdl.FileTypeSupport.Filters.Xliff.Infrastructure.ParagraphUnitBuilder.MatchParagraphElements()
at Sdl.FileTypeSupport.Filters.Xliff.Infrastructure.ParagraphUnitBuilder.CheckSegmentsAndMatch()
at Sdl.FileTypeSupport.Filters.Xliff.Infrastructure.ParagraphUnitBuilder.ProcessCurrentParagraphUnit()
at Sdl.FileTypeSupport.Filters.Xliff.Infrastructure.ParagraphUnitBuilder.OutputParagraphUnit()
at Sdl.FileTypeSupport.Filters.Xliff.Infrastructure.Consumers.AttributesConsumers.TranslateAttributeConsumer.Consume(XmlNodeParsed message)
at lambda_method(Closure , IMessage )
at Sdl.FileTypeSupport.Filters.Xliff.Infrastructure.InMemoryBus.Publish(IMessage message)
at Sdl.FileTypeSupport.Filters.Xliff.Extractor.ParserImpl.Publish(XmlNodeParsed message)
at Sdl.FileTypeSupport.Filters.Xliff.Infrastructure.XmlParser.Parse(XmlTextReader reader)
at Sdl.FileTypeSupport.Filters.Xliff.Extractor.ParserImpl.Parse(String xliffPath)
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

We have checked the xliff file and it is a valid xliff 1.2 file. Also, we can import it into another CAT tool we use (DVX). For this project however, we need to use Studio.

We reviewed the following thread, but it does not seem to be quite the same case: community.rws.com/.../bug-importing-xliff-1-2

Can anyone help provide clues as to why this may not be working? Here is an example the code in question:

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
<?xml version="1.0" encoding="UTF-8"?>
<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2" xmlns:okp="okapi-framework:xliff-extensions" xmlns:its="http://www.w3.org/2005/11/its" xmlns:itsxlf="http://www.w3.org/ns/its-xliff/" its:version="2.0">
<file original="/opt/tomcat/eol/tomcat/temp/1062-21-a27e5ec76869a021d9e777897c69cdb585470b8c.html" source-language="fr-FR" target-language="en-GB" datatype="html" okp:inputEncoding="UTF-8" okp:configId="/opt/tomcat/eol/config/tikal/plugins/okf_html@eolng-html.fprm">
<body> <trans-unit id="tu7" restype="x-paragraph">
<source xml:lang="fr-FR">ABC DEF GHI.</source>
<seg-source>
JKL MNF PQR
</seg-source>
<target xml:lang="en-GB"></target>
</trans-unit>
</body>
</file>
</xliff>
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Many thanks for your help!

emoji