Skip to content

Commit d897252

Browse files
committed
Python - distutils has been removed from Python 3.12, use shutil to copy script
1 parent 8718bb8 commit d897252

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

cadastre/cadastre_import.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
import tempfile
3131

3232
from datetime import datetime
33-
from distutils import dir_util
3433
from pathlib import Path
3534
from string import Template
3635

@@ -1010,7 +1009,7 @@ def copyFilesToTemp(self, source, target):
10101009

10111010
# copy script directory
10121011
try:
1013-
dir_util.copy_tree(source, target)
1012+
shutil.copytree(source, target)
10141013
os.chmod(target, 0o777)
10151014
except OSError as e:
10161015
msg = "<b>Erreur lors de la copie des scripts d'import: %s</b>" % e

0 commit comments

Comments
 (0)