Skip to content

Fix error when loading workbooks containing links that reference merged cells

Bitbucket Importer requested to merge bitbucket/merged-pr-362 into branch/3.0

Created originally on Bitbucket by Eiríkur Torfason

Was already merged in Bitbucket before import, marked as merged by the import user

We at GRID have come across .xlsx files that fail to load due to the issue described in #1260

This PR attempts to fix the issue.

  • In bind_hyperlinks, check if ref points to a MergedCell. If so, place link on the top-left cell of the merged range.
  • Extend test_merged_hyperlinks by adding a hyperlink pointing to a merged cell in complex-styles-worksheet.xml, then asserting that the link is placed on the top-left cell.

Locally, the tox tests are green across the board except for the pypy3 target that fails while installing dependencies.

Merge request reports