Document.updateFields hangs up occasionally

We have a production issue when call to document.updateFields() hangs rarely and only on one production instance. We are not able to find a reproducible test case but we can see it happens. Code hangs on that line call and we have to restart the app to get it resolved.
What could be the reason and how the document.updateFIelds() method is different from document.getRange().updateFields() ?

@Mariusz_Pala

The issue you’re experiencing with document.updateFields() hanging could be attributed to several factors, including the complexity of the document, the presence of circular references in fields, or resource limitations on the production instance. Since this occurs infrequently and without a reproducible test case, identifying the exact cause may be difficult.

The difference between document.updateFields() and document.getRange().updateFields() is significant: the former updates all fields in the document, while the latter restricts the update to fields within a specified range. If you are encountering performance issues, consider using getRange() to limit the update to only the necessary sections of the document, which may help alleviate the hanging problem.

If the issue continues, examine the document for specific conditions that could contribute to this behavior, such as complex field structures or large document sizes. Additionally, monitoring resource usage during the update process could provide insights into potential bottlenecks.

If you require further assistance, please consult the official documentation or community forums for additional support.

Should that API timeout instead of hanging indefinitely?

We are using Aspose.Words 25.2, were there any changes or fixes in that area since that version?

@Mariusz_Pala Unfortunately, without ability t reproduce the problem on our side, it is hard to answer what might cause the problem on your side. I would suggest you to update to the latest 25.10 version of Aspose.Words and check whether the problem still persists on your side.