Skip to content

Commit

Permalink
Use distutils provided by setuptools
Browse files Browse the repository at this point in the history
The distutils module provided by the stdlib has been deprecated in
Python 3.10. This PR sets an env var that is read by setuptools which
will shim its vendored copy of distutils if present avoiding a failure
once distutils is removed from the stdlib.

Signed-off-by: Jordan Borean <jborean93@gmail.com>
  • Loading branch information
jborean93 committed Oct 5, 2021
1 parent 2bde020 commit b091d0c
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
#!/usr/bin/env python
from __future__ import print_function

from setuptools import setup
from setuptools import Distribution
from setuptools.command.sdist import sdist
from setuptools.extension import Extension
import subprocess
import platform
import re
Expand All @@ -13,6 +9,13 @@
import shutil
import shlex

os.environ['SETUPTOOLS_USE_DISTUTILS'] = 'local'

from setuptools import setup
from setuptools import Distribution
from setuptools.command.sdist import sdist
from setuptools.extension import Extension


SKIP_CYTHON_FILE = '__dont_use_cython__.txt'

Expand Down

0 comments on commit b091d0c

Please sign in to comment.