Skip to content

Commit fe87c6a

Browse files
authored
Merge pull request #123 from blink1073/remove-distutils
2 parents 07d1eed + 269a425 commit fe87c6a

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

jupyter_packaging/setupbase.py

+3-4
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
from os.path import join as pjoin
1313
from pathlib import Path
1414
import io
15+
import logging
1516
import os
1617
import functools
1718
import pipes
@@ -27,17 +28,13 @@
2728
# shim deprecated to allow setuptools to find the version string in this file
2829
deprecated = lambda *args, **kwargs: lambda *args, **kwargs: None
2930

30-
# BEFORE importing distutils, remove MANIFEST. distutils doesn't properly
31-
# update it when the contents of directories change.
3231
if os.path.exists('MANIFEST'): os.remove('MANIFEST')
3332

3433
from packaging.version import VERSION_PATTERN
3534
from setuptools import Command
3635
from setuptools.command.build_py import build_py
3736
from setuptools.config import StaticModule
3837

39-
# Note: distutils must be imported after setuptools
40-
from distutils import log
4138

4239
from setuptools.command.sdist import sdist
4340
from setuptools.command.develop import develop
@@ -65,6 +62,8 @@ def list2cmdline(cmd_list):
6562
VERSION_REGEX = re.compile(r"^\s*" + VERSION_PATTERN + r"\s*$", re.VERBOSE | re.IGNORECASE)
6663

6764

65+
log = logging.getLogger(__name__)
66+
6867
if "--skip-npm" in sys.argv:
6968
print("Skipping npm install as requested.")
7069
skip_npm = True

setup.cfg

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ python_requires = >=3.7
2929
install_requires =
3030
packaging
3131
tomlkit
32-
setuptools>=46.4.0
32+
setuptools>=60.2.0
3333
wheel
3434
deprecation
3535

tests/utils.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def mock_dist():
1313
))
1414

1515
def run_command(cmd):
16-
"""Run a distutils/setuptools Command """
16+
"""Run a setuptools Command """
1717
dist = mock_dist()
1818
instance = cmd(dist)
1919
instance.initialize_options()

0 commit comments

Comments
 (0)