SuffolkLITLab / FormFyxer

A tool for learning about and pre-processing forms
MIT License
11 stars 1 forks source link

Refactor formfyxer to use PikePDF instead of pypdf2 by default #28

Closed nonprofittechy closed 2 years ago

nonprofittechy commented 2 years ago

https://github.com/SuffolkLITLab/FormFyxer/blob/45cb2b83ed9e3ba006e17c6b67882233f9a378d6/formfyxer/lit_explorer.py#L385

It looks like we're currently only using PikePDF if pypdf2 correctly sets the encrypted attribute, and then we just re-save the file as unencrypted. This doesn't seem to work though--see PDF I tested with in #27. It's possible that it's just that .encrypted is narrower than the set of things that prevent you from editing field names.

PikePDF is a newer better supported codebase and we might be able to remove pypdf2 as a dependency