Skip to content
This repository has been archived by the owner on Oct 9, 2023. It is now read-only.

"Distutils is deprecated" #88

Open
LouisDchrfP opened this issue Nov 17, 2021 · 5 comments
Open

"Distutils is deprecated" #88

LouisDchrfP opened this issue Nov 17, 2021 · 5 comments

Comments

@LouisDchrfP
Copy link

Hi !

This appear when running the outset command (cleanup or loading a script folder)

./outset --boot /usr/local/outset/./outset:38: 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 StrictVersion as version Boot processing complete

@arubdesu
Copy link
Contributor

Hey @LouisDchrfP what python did you install? What OS are you running? Please include information otherwise we can't tell what's going on.

@LouisDchrfP
Copy link
Author

LouisDchrfP commented Nov 17, 2021

Hi,
Running Big Sur 11.6.1 on a M1 MacBook Pro

python --version Python 2.7.16

python3 --version Python 3.10.0

@arubdesu
Copy link
Contributor

I reproduced this with current python.org 3.10, although it's just log noise and doesn't functionally stop outset from working.
This DeprecationWarning is explained in the listed PEP, which doesn't have a proposed alternative in stdlib, so I'm inclined to say we should ignore it on purpose (a la this SO post) until they kill distutils altogether 🙄

@arubdesu
Copy link
Contributor

There's another alternative, which is copying the .version module code local to outset and then the import goes away, which may be less work and stop the worry about total removal from python3.

@carlashley
Copy link
Contributor

There is a pkg_resources module which has some version utilities in it per https://stackoverflow.com/a/57634066.
The usual catches about making sure it works appropriately apply.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants