Strange string replacement issue
In my odt model I wrote this :
"do section- for p in listePages"
listePages is a python indexed array containing the values to insert into each page.
each page has a "SOCLOGO" value that is strictly the same for every page : "logo_groupe_
I use this code to insert a picture on top of each page :
do text if len(p['SOCLOGO'])>0
This works well for the first pages, but with large document rendering, after several tests I always face an issue starting page 232:
Error while evaluating the expression "document(
File "<string>", line 1, in <module>
imp = importer(content, at, format, self.tempFolder, ns)
self.importPath = self.moveFile(
fdst = open(dst, 'wb')
That's strange because if I temporarily display the p['SOCLOGO'] value as-is in the pages it is OK, "logo_groupe_
Where can it come from ? Looks like a memory issue.
You can get the generated file here : http://
(I remove the logos on first pages for confidentiality and removed the first pages, left some of the good ones then firsts of the wrong ones).
Any help would be much appreciated, we face this issue on a production system for many employees.