Package: release.debian.org
Severity: normal
X-Debbugs-Cc: python3-stdlib-extensi...@packages.debian.org
Control: affects -1 + src:python3-stdlib-extensions
User: release.debian....@packages.debian.org
Usertags: unblock

Please unblock package python3-stdlib-extensions

As discussed in-person, I left this out from #1108661, because I forgot. 
It isn't critical at all, but is probably what people expect.

The diff is attached, but isn't even relevant, because the packages are 
transitional.

[ Reason ]
Brings python3-stdlib-extensions back into line with python3.13.

[ Impact ]
Potential user confusion.

[ Tests ]
Not even relevant.

[ Risks ]
Nope

[ Checklist ]
  [x] all changes are documented in the d/changelog
  [x] I reviewed all changes and I approve them
  [x] attach debdiff against the package in testing

[ Other info ]

unblock python3-stdlib-extensions/3.13.5-1
diff -Nru 
python3-stdlib-extensions-3.13.3/3.13/Modules/mimalloc/mimalloc/internal.h 
python3-stdlib-extensions-3.13.5/3.13/Modules/mimalloc/mimalloc/internal.h
--- python3-stdlib-extensions-3.13.3/3.13/Modules/mimalloc/mimalloc/internal.h  
2025-04-08 15:54:08.000000000 +0200
+++ python3-stdlib-extensions-3.13.5/3.13/Modules/mimalloc/mimalloc/internal.h  
2025-06-11 17:36:57.000000000 +0200
@@ -634,10 +634,10 @@
   mi_track_mem_defined(block,sizeof(mi_block_t));
   mi_block_t* next;
   #ifdef MI_ENCODE_FREELIST
-  next = (mi_block_t*)mi_ptr_decode(null, block->next, keys);
+  next = (mi_block_t*)mi_ptr_decode(null, 
mi_atomic_load_relaxed((_Atomic(mi_encoded_t)*)&block->next), keys);
   #else
   MI_UNUSED(keys); MI_UNUSED(null);
-  next = (mi_block_t*)block->next;
+  next = 
(mi_block_t*)mi_atomic_load_relaxed((_Atomic(mi_encoded_t)*)&block->next);
   #endif
   mi_track_mem_noaccess(block,sizeof(mi_block_t));
   return next;
@@ -646,10 +646,10 @@
 static inline void mi_block_set_nextx(const void* null, mi_block_t* block, 
const mi_block_t* next, const uintptr_t* keys) {
   mi_track_mem_undefined(block,sizeof(mi_block_t));
   #ifdef MI_ENCODE_FREELIST
-  block->next = mi_ptr_encode(null, next, keys);
+  mi_atomic_store_relaxed(&block->next, mi_ptr_encode(null, next, keys));
   #else
   MI_UNUSED(keys); MI_UNUSED(null);
-  block->next = (mi_encoded_t)next;
+  mi_atomic_store_relaxed(&block->next, (mi_encoded_t)next);
   #endif
   mi_track_mem_noaccess(block,sizeof(mi_block_t));
 }
diff -Nru 
python3-stdlib-extensions-3.13.3/3.13/Modules/mimalloc/mimalloc/types.h 
python3-stdlib-extensions-3.13.5/3.13/Modules/mimalloc/mimalloc/types.h
--- python3-stdlib-extensions-3.13.3/3.13/Modules/mimalloc/mimalloc/types.h     
2025-04-08 15:54:08.000000000 +0200
+++ python3-stdlib-extensions-3.13.5/3.13/Modules/mimalloc/mimalloc/types.h     
2025-06-11 17:36:57.000000000 +0200
@@ -235,7 +235,7 @@
 
 // free lists contain blocks
 typedef struct mi_block_s {
-  mi_encoded_t next;
+  _Atomic(mi_encoded_t) next;
 } mi_block_t;
 
 
diff -Nru python3-stdlib-extensions-3.13.3/3.13/Modules/pycore_bytesobject.h 
python3-stdlib-extensions-3.13.5/3.13/Modules/pycore_bytesobject.h
--- python3-stdlib-extensions-3.13.3/3.13/Modules/pycore_bytesobject.h  
2025-04-08 15:54:08.000000000 +0200
+++ python3-stdlib-extensions-3.13.5/3.13/Modules/pycore_bytesobject.h  
2025-06-11 17:36:57.000000000 +0200
@@ -20,6 +20,10 @@
 
 // Helper for PyBytes_DecodeEscape that detects invalid escape chars.
 // Export for test_peg_generator.
+PyAPI_FUNC(PyObject*) _PyBytes_DecodeEscape2(const char *, Py_ssize_t,
+                                             const char *,
+                                             int *, const char **);
+// Export for binary compatibility.
 PyAPI_FUNC(PyObject*) _PyBytes_DecodeEscape(const char *, Py_ssize_t,
                                             const char *, const char **);
 
diff -Nru python3-stdlib-extensions-3.13.3/3.13/Modules/pycore_object.h 
python3-stdlib-extensions-3.13.5/3.13/Modules/pycore_object.h
--- python3-stdlib-extensions-3.13.3/3.13/Modules/pycore_object.h       
2025-04-08 15:54:08.000000000 +0200
+++ python3-stdlib-extensions-3.13.5/3.13/Modules/pycore_object.h       
2025-06-11 17:36:57.000000000 +0200
@@ -165,6 +165,23 @@
 extern void _Py_SetImmortal(PyObject *op);
 extern void _Py_SetImmortalUntracked(PyObject *op);
 
+// Checks if an object has a single, unique reference. If the caller holds a
+// unique reference, it may be able to safely modify the object in-place.
+static inline int
+_PyObject_IsUniquelyReferenced(PyObject *ob)
+{
+#if !defined(Py_GIL_DISABLED)
+    return Py_REFCNT(ob) == 1;
+#else
+    // NOTE: the entire ob_ref_shared field must be zero, including flags, to
+    // ensure that other threads cannot concurrently create new references to
+    // this object.
+    return (_Py_IsOwnedByCurrentThread(ob) &&
+            _Py_atomic_load_uint32_relaxed(&ob->ob_ref_local) == 1 &&
+            _Py_atomic_load_ssize_relaxed(&ob->ob_ref_shared) == 0);
+#endif
+}
+
 // Makes an immortal object mortal again with the specified refcnt. Should only
 // be used during runtime finalization.
 static inline void _Py_SetMortal(PyObject *op, Py_ssize_t refcnt)
diff -Nru python3-stdlib-extensions-3.13.3/3.13/Modules/pycore_runtime.h 
python3-stdlib-extensions-3.13.5/3.13/Modules/pycore_runtime.h
--- python3-stdlib-extensions-3.13.3/3.13/Modules/pycore_runtime.h      
2025-04-08 15:54:08.000000000 +0200
+++ python3-stdlib-extensions-3.13.5/3.13/Modules/pycore_runtime.h      
2025-06-11 17:36:57.000000000 +0200
@@ -60,7 +60,7 @@
 } _Py_AuditHookEntry;
 
 typedef struct _Py_DebugOffsets {
-    char cookie[8];
+    char cookie[8] _Py_NONSTRING;
     uint64_t version;
     uint64_t free_threaded;
     // Runtime state offset;
diff -Nru python3-stdlib-extensions-3.13.3/3.13/Modules/pycore_unicodeobject.h 
python3-stdlib-extensions-3.13.5/3.13/Modules/pycore_unicodeobject.h
--- python3-stdlib-extensions-3.13.3/3.13/Modules/pycore_unicodeobject.h        
2025-04-08 15:54:08.000000000 +0200
+++ python3-stdlib-extensions-3.13.5/3.13/Modules/pycore_unicodeobject.h        
2025-06-11 17:36:57.000000000 +0200
@@ -142,6 +142,19 @@
 // Helper for PyUnicode_DecodeUnicodeEscape that detects invalid escape
 // chars.
 // Export for test_peg_generator.
+PyAPI_FUNC(PyObject*) _PyUnicode_DecodeUnicodeEscapeInternal2(
+    const char *string,     /* Unicode-Escape encoded string */
+    Py_ssize_t length,      /* size of string */
+    const char *errors,     /* error handling */
+    Py_ssize_t *consumed,   /* bytes consumed */
+    int *first_invalid_escape_char, /* on return, if not -1, contain the first
+                                       invalid escaped char (<= 0xff) or 
invalid
+                                       octal escape (> 0xff) in string. */
+    const char **first_invalid_escape_ptr); /* on return, if not NULL, may
+                                        point to the first invalid escaped
+                                        char in string.
+                                        May be NULL if errors is not NULL. */
+// Export for binary compatibility.
 PyAPI_FUNC(PyObject*) _PyUnicode_DecodeUnicodeEscapeInternal(
     const char *string,     /* Unicode-Escape encoded string */
     Py_ssize_t length,      /* size of string */
diff -Nru python3-stdlib-extensions-3.13.3/debian/changelog 
python3-stdlib-extensions-3.13.5/debian/changelog
--- python3-stdlib-extensions-3.13.3/debian/changelog   2025-04-09 
07:14:59.000000000 +0200
+++ python3-stdlib-extensions-3.13.5/debian/changelog   2025-07-13 
13:01:15.000000000 +0200
@@ -1,3 +1,19 @@
+python3-stdlib-extensions (3.13.5-1) unstable; urgency=medium
+
+  * Update 3.13 extensions and modules to the 3.13.5 release.
+
+ -- Matthias Klose <d...@debian.org>  Sun, 13 Jul 2025 13:01:15 +0200
+
+python3-stdlib-extensions (3.13.4-1) unstable; urgency=medium
+
+  * Update 3.13 extensions and modules to the 3.13.4 release.
+  * Update 3.12 extensions and modules to the 3.12.11 release.
+  * Update 3.11 extensions and modules to the 3.11.13 release.
+  * Update 3.10 extensions and modules to the 3.10.18 release.
+  * Update 3.9 extensions and modules to the 3.9.23 release.
+
+ -- Matthias Klose <d...@debian.org>  Wed, 04 Jun 2025 15:58:24 +0200
+
 python3-stdlib-extensions (3.13.3-1) unstable; urgency=medium
 
   * Update 3.13 extensions and modules to the 3.13.3 release.
diff -Nru python3-stdlib-extensions-3.13.3/debian/control 
python3-stdlib-extensions-3.13.5/debian/control
--- python3-stdlib-extensions-3.13.3/debian/control     2025-03-04 
16:33:05.000000000 +0100
+++ python3-stdlib-extensions-3.13.5/debian/control     2025-06-04 
15:59:54.000000000 +0200
@@ -31,14 +31,14 @@
 #  python3.12-dbg:any,
   libpython3.13-dev,
   libpython3.13-dbg,
-  python3.13-dev:any (>= 3.13.0~rc1-2~),
+  python3.13-dev:any (>= 3.13.4-1~),
   python3.13-dbg:any,
 #  tk-dev, blt-dev (>= 2.4z-9),
 #  libgdbm-dev, libgdbm-compat-dev,
 #  libgdbm-dev, libdb-dev,
   python3-setuptools,
 Build-Conflicts: tcl8.4-dev, tk8.4-dev, tcl8.5-dev, tk8.5-dev
-Standards-Version: 4.7.0
+Standards-Version: 4.7.2
 Vcs-Git: https://salsa.debian.org/cpython-team/python3-stdlib.git
 Vcs-Browser: https://salsa.debian.org/cpython-team/python3-stdlib
 

Reply via email to