Hi,
I'm not in the Cloud Team but on Python Team, so I'm sending this as a
patch instead of pushing to Salsa. It makes the six import in
botocore/compat.py optional and drops python3-six from Depends and
Build-Depends. No package in Debian uses botocore.compat.six. Build,
unit tests and autopkgtest pass, and boto3, s3transfer and aiobotocore
import fine without six.
greetings
--
Nico Della Torre - nicoz
Debian Contributor - Ubuntu Member - PSF Member
Debian: https://wiki.debian.org/nicoz
Ubuntu: https://wiki.ubuntu.com/nicoz91
Launchpad: https://launchpad.net/~nicoz91
IRC: nicoz (OFTC, Libera.Chat)
GPG: 0456 E8BC 1DC0 B027 EF8D 66A6 9549 3787 F6F1 9F03
From 5270cbab29c51060eeb91db1a4bb70d9e7a15541 Mon Sep 17 00:00:00 2001
From: Nico Della Torre <[email protected]>
Date: Thu, 22 Oct 2026 10:33:03 +0200
Subject: [PATCH] Make the six import optional and drop python3-six dependency
---
debian/changelog | 6 ++++++
debian/control | 2 --
debian/patches/0001-Don-t-use-duplicated-modules.patch | 7 +++++--
3 files changed, 11 insertions(+), 4 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 52958a08..b80a8167 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+python-botocore (1.40.72+repack-2) UNRELEASED; urgency=medium
+
+ * Make the six import optional and drop the dependency on python3-six
+
+ -- Nico Della Torre <[email protected]> Thu, 22 Oct 2026 10:26:24 +0200
+
python-botocore (1.40.72+repack-1) unstable; urgency=medium
* New upstream version 1.40.72+repack
diff --git a/debian/control b/debian/control
index bc02821e..d66a777e 100644
--- a/debian/control
+++ b/debian/control
@@ -12,7 +12,6 @@ Build-Depends: debhelper-compat (= 12)
, python3-jmespath <!nocheck>
, python3-pytest <!nocheck>
, python3-requests <!nocheck>
- , python3-six <!nocheck>
, dh-python
Standards-Version: 4.6.2
Homepage: https://github.com/boto/botocore
@@ -24,7 +23,6 @@ Package: python3-botocore
Architecture: all
Depends: ${python3:Depends},
python3-requests,
- python3-six,
python3-dateutil (>= 2.1),
python3-jmespath (>= 0.7.1),
${misc:Depends}
diff --git a/debian/patches/0001-Don-t-use-duplicated-modules.patch b/debian/patches/0001-Don-t-use-duplicated-modules.patch
index 0a4af430..8f840e09 100644
--- a/debian/patches/0001-Don-t-use-duplicated-modules.patch
+++ b/debian/patches/0001-Don-t-use-duplicated-modules.patch
@@ -19,12 +19,15 @@ Subject: Don't use duplicated modules
--- a/botocore/compat.py
+++ b/botocore/compat.py
-@@ -26,7 +26,7 @@
+@@ -26,7 +26,10 @@
from collections.abc import MutableMapping
from math import floor
-from botocore.vendored import six
-+import six
++try:
++ import six
++except ImportError:
++ pass
from botocore.exceptions import MD5UnavailableError
from dateutil.tz import tzlocal
from urllib3 import exceptions
--
2.55.0