File: setuptools-60

package info (click to toggle)
python-pyhcl 0.4.4-2.1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 684 kB
  • sloc: python: 3,833; makefile: 23; sh: 6
file content (28 lines) | stat: -rw-r--r-- 940 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
Description: Import setuptools before distutils
 setuptools 60 uses its own bunlded version of distutils, by default. It
 injects this into sys.modules, at import time. So we need to make sure that it
 is imported, before anything else imports distutils, to ensure everything is
 using the same distutils version.
 .
 This is to prepare for Python 3.12, which will drop distutils.
Author: Stefano Rivera <stefanor@debian.org>
Forwarded: https://github.com/virtuald/pyhcl/pull/84
Bug-Debian: https://bugs.debian.org/1022318
--- a/setup.py
+++ b/setup.py
@@ -3,13 +3,14 @@
 from __future__ import print_function
 
 from os.path import abspath, dirname, join, exists
-from distutils.core import setup
 
 try:
     from setuptools.command.build_py import build_py as _build_py
 except ImportError:
     from distutils.command.build_py import build_py as _build_py
 
+from distutils.core import setup
+
 import os
 import sys
 import subprocess