Closed gouttegd closed 3 years ago
Thanks - looks good. cc @knabar
NB: we haven't looked at supporting Python 3.8 yet (see https://docs.openmicroscopy.org/omero/5.6.1/sysadmins/version-requirements.html#python) but happy to receive any help in that direction.
For what it’s worth, I’ve been running OMERO under Python 3.8 for a little bit more than one month, and the problem with the Figure_To_Pdf.py script is the only issue I’ve run into so far.
The escape function in the cgi module has been deprecated since Python 3.2 [1] and has finally been removed in Python 3.8 [2], resulting in the Figure_To_Pdf.py script failing to run under Python 3.8.
This patch replaces the call to cgi.escape by html.escape, as recommended by the Python developers.
[1] https://docs.python.org/3.7/library/cgi.html#cgi.escape [2] https://docs.python.org/3.8/whatsnew/3.8.html#api-and-feature-removals