Work item comment leads to corrupt live doc

Description
lothar_news@gmx.de
Posts: 4
Joined: Wed Mar 14, 2007 11:03 am

Work item comment leads to corrupt live doc

Postby lothar_news@gmx.de » Wed Mar 14, 2007 11:16 am

Hello all,

I am observing the following behaviour: When I add a comment to a workitem stored in a live document using the web interface the live doc gets corrupt. When I try to open the document offline in my SVN sandbox, Word comes up with an error message saying that the document cannot be opened due to content-related problems:
"Die XML-Datei <...> kann nicht geöffnet werden, da ihr Inhalt Probleme verursacht."

Doing some further analysis I found out that the problem is caused by paragraph tags <w:p> included in the polarion <comment> section. When I throw them out using a plain text editor, Word doesn't complain anymore.

Is this a known problem?

Best regards,
Lothar, Bonn/Germany

dobisekm
Posts: 118
Joined: Wed Mar 23, 2005 3:29 pm
Location: Prague, Czech Republic

Postby dobisekm » Fri Mar 16, 2007 3:11 pm

Hi Lothar,

this is not a known problem - such usecase should work normally. However, it might be caused by a corrupted Word LiveDoc template. Did you use the default one or did you create your own?

Does the problem occur in all livedocs or jus some?

Does it occur for all comments (even e.g. one word) or just some special ones?

Michal Dobisek
Polarion Support

lothar_news@gmx.de
Posts: 4
Joined: Wed Mar 14, 2007 11:03 am

Postby lothar_news@gmx.de » Tue Mar 20, 2007 9:29 am

Hi Michal,

we started with the standard template, then copied about 100 pages of text into the document. We then worked through the text and inserted work items. We surrounded the relevant passages with <description> tags.
The type of comment we used had test character, e.g. "this is another test comment".
The problem did not occur with the livedocs which we created when following the tutorial.
Surprisingly, the corrupt document is still valid against the Word XML schema (I checked that explicitly) so it might be concluded that it's not Polarion generating some false XML but Word not being able to interpret it.

This is the "malicious" code extract:

Code: Select all

<comments><w:r><w:rPr><w:vanish/></w:rPr><w:t>leer</w:t></w:r><w:p><w:pPr><w:spacing w:before="100"/><w:rPr><w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:cs="Arial"/><wx:font wx:val="Arial"/><w:sz w:val="16"/><w:sz-cs w:val="16"/></w:rPr></w:pPr><w:r><w:rPr><w:b/><w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:cs="Arial"/><wx:font wx:val="Arial"/><w:sz w:val="16"/><w:sz-cs w:val="16"/></w:rPr><w:t>Comment added by:lnieswan</w:t></w:r></w:p><comment author="lnieswan"><w:p><w:pPr><w:rPr><w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:cs="Arial"/><wx:font wx:val="Arial"/><w:sz w:val="16"/><w:sz-cs w:val="16"/></w:rPr></w:pPr><w:r><w:rPr><w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:cs="Arial"/><wx:font wx:val="Arial"/><w:sz w:val="16"/><w:sz-cs w:val="16"/></w:rPr><w:t>Test-Kommentar von Lothar</w:t></w:r></w:p></comment></comments>


When you strip all <w:p> tags, the problem disappears.

Lothar

Stepan Roh
Posts: 34
Joined: Tue Apr 04, 2006 8:46 am

Postby Stepan Roh » Mon Mar 26, 2007 11:21 am

Hello.

I can confirm that your <comments> snippet is refused by Word 2003, however if I remove following piese of XML, Word will open it:

<w:r><w:rPr><w:vanish/></w:rPr><w:t>leer</w:t></w:r>


The <w:p> are perfectly legal. Don't you know where that "leer" came from? Is it from your test text?
Stepan Roh
Polarion Software

lothar_news@gmx.de
Posts: 4
Joined: Wed Mar 14, 2007 11:03 am

Postby lothar_news@gmx.de » Mon Mar 26, 2007 2:22 pm

Yes, the string "leer" results from our tests. It's a german word and means 'empty'. We use this string to be able to search for empty fields, i.e. as a replacement for a null value.

Stepan Roh
Posts: 34
Joined: Tue Apr 04, 2006 8:46 am

Postby Stepan Roh » Tue Mar 27, 2007 9:33 am

So if I understand you correctly you take Word template, type "leer" inside <comments></comments>, add comment from within the Polarion WebUI and then try to open it in Word which chokes on it? Is that right?
Stepan Roh

Polarion Software

lothar_news@gmx.de
Posts: 4
Joined: Wed Mar 14, 2007 11:03 am

Postby lothar_news@gmx.de » Tue Mar 27, 2007 10:46 am

Correct. I cannot confirm, tough, that removing the "leer"-section repairs the document. I can send it to you if you like.

Stepan Roh
Posts: 34
Joined: Tue Apr 04, 2006 8:46 am

Postby Stepan Roh » Wed Mar 28, 2007 9:36 am

Does it work if you repeat your steps, but do not put any "leer"s inside of <comments> at the first place?
Stepan Roh

Polarion Software


Return to “Polarion Application Lifecycle Management (ALM)”

Who is online

Users browsing this forum: No registered users and 10 guests