{"action":"created","issue":{"url":"https://api.github.com/repos/opensagres/xdocreport/issues/77","labels_url":"https://api.github.com/repos/opensagres/xdocreport/issues/77/labels{/name}","comments_url":"https://api.github.com/repos/opensagres/xdocreport/issues/77/comments","events_url":"https://api.github.com/repos/opensagres/xdocreport/issues/77/events","html_url":"https://github.com/opensagres/xdocreport/issues/77","id":109117343,"number":77,"title":"In case of specific word document.xml structure, template parsing fail.","user":{"login":"kevinsdooapp","id":2072116,"avatar_url":"https://avatars.githubusercontent.com/u/2072116?v=3","gravatar_id":"","url":"https://api.github.com/users/kevinsdooapp","html_url":"https://github.com/kevinsdooapp","followers_url":"https://api.github.com/users/kevinsdooapp/followers","following_url":"https://api.github.com/users/kevinsdooapp/following{/other_user}","gists_url":"https://api.github.com/users/kevinsdooapp/gists{/gist_id}","starred_url":"https://api.github.com/users/kevinsdooapp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kevinsdooapp/subscriptions","organizations_url":"https://api.github.com/users/kevinsdooapp/orgs","repos_url":"https://api.github.com/users/kevinsdooapp/repos","events_url":"https://api.github.com/users/kevinsdooapp/events{/privacy}","received_events_url":"https://api.github.com/users/kevinsdooapp/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":14,"created_at":"2015-09-30T15:32:14Z","updated_at":"2015-11-17T15:18:00Z","closed_at":null,"body":"Hi everyone!\r\n\r\nGiven a template, I success to generate a report. But if I open the template with word (add a space, remove the space, save the document =  no real change), the parsing of the template will not be possible anymore.\r\n\r\n```\r\nException in thread \"main\" org.apache.velocity.exception.ParseErrorException: Encountered \"#end\" at fr.opensagres.xdocreport.document.docx.DocxReport@19d02cb!word/document.xml[line 1, column 82455]\r\n```\r\n\r\nI lost a lot of time debugging and trying to understand why my template is impossible to parse when I edit it with word. Is it a velocity parser problem or a word problem? To easily understand and reproduce the problem, please checkout the test project below.\r\n\r\n[https://github.com/kevinsdooapp/xdocreport-issue-77.git](https://github.com/kevinsdooapp/xdocreport-issue-77.git)\r\n\r\nThank you in advance for your help!\r\n\r\nKévin\r\n"},"comment":{"url":"https://api.github.com/repos/opensagres/xdocreport/issues/comments/157400534","html_url":"https://github.com/opensagres/xdocreport/issues/77#issuecomment-157400534","issue_url":"https://api.github.com/repos/opensagres/xdocreport/issues/77","id":157400534,"user":{"login":"angelozerr","id":1932211,"avatar_url":"https://avatars.githubusercontent.com/u/1932211?v=3","gravatar_id":"","url":"https://api.github.com/users/angelozerr","html_url":"https://github.com/angelozerr","followers_url":"https://api.github.com/users/angelozerr/followers","following_url":"https://api.github.com/users/angelozerr/following{/other_user}","gists_url":"https://api.github.com/users/angelozerr/gists{/gist_id}","starred_url":"https://api.github.com/users/angelozerr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/angelozerr/subscriptions","organizations_url":"https://api.github.com/users/angelozerr/orgs","repos_url":"https://api.github.com/users/angelozerr/repos","events_url":"https://api.github.com/users/angelozerr/events{/privacy}","received_events_url":"https://api.github.com/users/angelozerr/received_events","type":"User","site_admin":false},"created_at":"2015-11-17T15:18:00Z","updated_at":"2015-11-17T15:18:00Z","body":"> I'm trying to reduce the template size but when I remove a large part of it, I cannot reproduce the problem\r\n\r\nYes it's the problem, but we need to discover the problem with simple case and add a JUnit for that. Tour word/document.xml has 2 fields and content to debug the preprocessor. You must rmove some part, check you have problems, remove again some part as so one. It's a awful job, but me I have no time to do that. \r\n\r\n> could you indicate me the way to remove the bookmark _GoBack during preprocessing\r\n\r\nXDocReport doesn't remove _GoBack . As I said you, it's not a problem with _GoBack. Please compare your 2 word/document.xml from enveloppe-template_fr.docx and enveloppe-template_fr_fail.docx and you will see that there are a lot of differences (not only _GoBack). I suggest you that you format the word/document.xml and uses compare tools like Eclipse/Compare Each Other.\r\n\r\n> If template cannot be edited easily (so with MS Word), it's useless...\r\n\r\nI agree with you, it's the goal of XDocReport, but to be honnest with you, it's the first time that we have this issue. I have spend a long time to try to udnerstand the problem, but I'm discouraged with your big file.\r\n\r\n> If you follow the last example I provided, there is no reason for xdocreport to fail processing since the only difference is that the bookmark _GoBack has been removed.\r\n\r\nAs I said you, please compar eteh word/document.xml, you will see that there are a lot of differences, not only _GoBack ."}}