unoconv / unoserver

MIT License
495 stars 69 forks source link

DeprecationWarning Is this slated to be fixed? #92

Closed jfines closed 6 months ago

jfines commented 8 months ago

System Info

Operating System: Ubuntu 22.04.3 LTS Architecture: 64 bit Hardware Model: HP HP ENVY Laptop 17-cg1xxx Graphics: NVIDIA Corporation TU117M [GeForce MX450] / Mesa Intel® Xe Graphics (TGL GT2) Gnome Version: 42.9 Windowing System: X11

Problem

When running unoconv from the command line (gnome-terminal) on my local system I receive the following warning..

DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
  from distutils.version import LooseVersion

The files are apparently converted successfully but the warning is output to the command line nevertheless.

Steps to Reproduce

On a fresh Ubuntu 22.04 installation which has been updated up to the date of this post run..

# Use default options
unoconv file [file2 ..]

View output.

Desired Outcome

  1. unoconv not to stop working at some time in the near future
  2. To receive a response indicating whether this is a known issue and if / what is planned to resolve it.

Thanks so much. I just found out about unoconv today and used for the first time. I like the utiliy (it is extremely useful) and wish the best for it and everyone involved.

Thanks for creating it for us.

regebro commented 8 months ago

No, sorry, I was thinking of setuptools, it's slated to move to use pyproject.toml instead and not directly require setuptools.

I don't know why you get that warning, there is nothing in unoserver that directly uses distutils.

janhec commented 3 months ago

Note that unconv may be old and is (being) replaced by unoserver. However, the featureset of the latter, in my recollection, was not (yet) said to be complete. I have unoconv version 0.9.0, python 3.10.12, So I changed line 19 of unoconv in .local\bin from: from distutils.version import LooseVersion to: from packaging.version import parse as LooseVersion and all seems well. Of course you may have to use 'pip install packaging' especially on an older python (e.g. 3.9.x)