Package: src:fonttools
Version: 4.62.1-7
User: [email protected]
Usertags: python3.15-default
Tags: patch, ftbfs, forky, sid
Severity: important

Hi!

While rebuilding the python related packages against the Python 3.15rc2
as the default version we found that fonttools fails to build from
source [1].

The error is:

AttributeError: module 'glob' has no attribute 'glob1'. Did you mean '.glob' 
instead of '.glob1'?

This happens because glob1 is deprecated. The solution is to replace
with glob(GLOB, root_dir=DIR)

I've applied this fix in the sandbox [2] to verify that it builds
successfully, please consider applying the patch to support the upcoming
3.15 version.

Setting the severity to important for now. Once Python 3.15 becomes the
default version this bug will become release critical.

Happy hacking,

[1]: https://debusine.debian.net/debian/r-python-python3.15/artifact/4749290/
[2]: https://debusine.debian.net/debian/r-python-python3.15/

--
"Can you imagine what I would do if I could do all I can?" -- Sun Tzu
Saludos /\/\ /\ >< `/
From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <[email protected]>
Date: Sat, 11 Jul 2026 19:52:51 +0200
Subject: Replace private `glob.glob1()` with `glob.glob(..., root_dir=...)`

Replace the use of undocumented `glob.glob1()` function that was removed
in Python 3.15 with its equivalent `glob.glob(..., root_dir=...)`.  This
fixes compatibility with Python 3.15 (where the function is removed),
and works all the way down to Python 3.10.

See: https://docs.python.org/3.13/whatsnew/3.13.html#new-deprecations

Signed-off-by: Michał Górny <[email protected]>
---
 MetaTools/buildTableList.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/MetaTools/buildTableList.py b/MetaTools/buildTableList.py
index b344f330f..9bdd95642 100755
--- a/MetaTools/buildTableList.py
+++ b/MetaTools/buildTableList.py
@@ -12,7 +12,7 @@ fontToolsDir = os.path.normpath(fontToolsDir)
 tablesDir = os.path.join(fontToolsDir, "Lib", "fontTools", "ttLib", "tables")
 docFile = os.path.join(fontToolsDir, "Doc/source/ttx.rst")
 
-names = glob.glob1(tablesDir, "*.py")
+names = glob.glob("*.py", root_dir=tablesDir)
 
 modules = []
 tables = []

Reply via email to