question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

File corruption likely due to duplicate image IDs in document

See original GitHub issue

Hi guys,

First of all, I don’t think this is actually any issue with the package at all, but have a strange scenario… We have 2 separate document templates, both of them should be pulling in the same set of images (using IMAGE tag)- but in 1 document, the file is perfect, the other always shows the error in Word that the document is corrupted. After letting Word recover it, the document all looks perfect.

So, there seems to be something else in the template that is causing an issue, but, only when the images are inserted (no matter where the image is inserted within the template & no matter what URL is provided). Both documents use the same set of URL’s, the same image dimensions & the same additionalJSContext function called - so I know it works & has worked for many other templates.

Being that it is hard to even reproduce the issue (unfortunately I can’t share the template with you in entirety, as it belongs to our customer), I am really just wondering if there are any methods you may know that can help locate the source of the corruption in the document?

Word just magically resolves the issue, but without indication of what it did to fix it & looking at the XML hasn’t helped, as I don’t really know what I am looking for.

I tried a Microsoft SDK that was suggested online, but I have little/no idea when it comes to .net & I couldn’t get it to read the file (probably because I am on Mac), plus I am not really sure if it would have provided the answer for this issue.

Happy for you to just close this off, if there is nothing that comes to mind. Thanks 😃

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7

github_iconTop GitHub Comments

1reaction
jjhbwcommented, Feb 15, 2021

Hmmm this issue comes to mind #144 .

Also, have you tried saving the offending template again in the newest version of Word? Maybe edit it a bit to ensure Word actually parses and serialises it again. That way it may clean up some of the offending xml. Just a shot in the dark.

0reactions
jjhbwcommented, Jun 3, 2021

Should be fixed in v4.6.2. Will be published to NPM shortly.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Image corruption can cause status 190's on duplications.
If images are corrupt, it's possible that the SLP duplication jobs will not be able to properly duplicate the image, which will trigger...
Read more >
How to repair corrupt AutoCAD files
Remove duplicate or overlapping objects in the drawing with the OVERKILL command (see Using OVERKILL to remove duplicate or overlapping objects ...
Read more >
[Solved] Automatically created duplicate images - (View topic)
The quickest was is to copy everything else except the images, and paste it into a new, empty document (File > New >...
Read more >
How do I remove duplicate image files from 'Apple Photos'?
When I am using PowerPhotos or Photo Sweeper, they will present possible duplicates side by side, and I am manually selecting the keepers....
Read more >
Resolve issues with documents in Hubdoc - Xero Central
Resolve issues you have getting a document into Hubdoc, data not ... Potential duplicate documents ... Issues caused by auto-fill.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found