ShayHill / docx2python

Extract docx headers, footers, (formatted) text, footnotes, endnotes, properties, and images.
https://docx2python.readthedocs.io/en/latest/
MIT License
164 stars 35 forks source link

Add changelog file and tag releases as git tags? #8

Closed peterfarrell closed 4 years ago

peterfarrell commented 4 years ago

Hi,

We noticed a new version of the library on PyPI but we don't know what has changed in this release. As a way to aid people in learning about the changes, would it be possible for you to:

  1. Start a changelog file in the root of the project?
  2. Tag each release a git tag so it's possible to compare branches/tags against each other?

Thanks and let me know if there is anything I can do to assist in this.

ShayHill commented 4 years ago

Thank you for the suggestions. I have added both. Here is the change from 1.24 to 1.25

---- version 1.25 - 200820 Added support for Table of Contents text

A docx table of contents is built like a set of hyperlinks, with each hyperlink element's having an anchor (internal link) instead of an href (external link).

Previously any document with a Table of Contents would fail with KeyError: '{http://schemas.openxmlformats.org/officeDocument/2006/relationships}id' after failing to find an href. Now, docx2python will continue without warning if an href is not found in a hyperlink element. In an href is found, docx2python will print the href inside '<a href="{}">' as before. Anchor (internal link) elements are meaningless outside the docx and are therefore ignored by docx2python.