void-packages/srcpkgs/python3-nbclassic/patches/python3.13.patch
2024-12-14 07:43:34 -05:00

41 lines
1.3 KiB
Diff

From 2545d900b40bbb9fa3ea266afa617e6e0be70c71 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Lum=C3=ADr=20=27Frenzy=27=20Balhar?= <lbalhar@redhat.com>
Date: Sat, 7 Sep 2024 03:37:00 +0200
Subject: [PATCH] Replace pipes with shlex (#286)
pipes module has been deprecated in Python 3.11 and removed in 3.13. https://peps.python.org/pep-0594/
---
setupbase.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/setupbase.py b/setupbase.py
index 80f28b6eb..4e7a4feec 100644
--- a/setupbase.py
+++ b/setupbase.py
@@ -12,7 +12,7 @@
import os
import re
-import pipes
+import shlex
import shutil
import sys
@@ -27,7 +27,7 @@
from subprocess import list2cmdline
else:
def list2cmdline(cmd_list):
- return ' '.join(map(pipes.quote, cmd_list))
+ return ' '.join(map(shlex.quote, cmd_list))
#-------------------------------------------------------------------------------
# Useful globals and utility functions
@@ -486,7 +486,7 @@ def run(self):
try:
run(['lessc',
'--source-map',
- '--include-path=%s' % pipes.quote(static),
+ '--include-path=%s' % shlex.quote(static),
src,
dst,
], cwd=repo_root, env=env)