From 12200ed1385e79e763517ef0fbdba74b92851e94 Mon Sep 17 00:00:00 2001 From: Sebastian Rittau Date: Fri, 12 Jun 2026 12:03:31 +0200 Subject: [PATCH] [pyexpat] Billion laughs mitigation methods backported to 3.13 and 3.14 Fixes #15898 --- stdlib/pyexpat/__init__.pyi | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/stdlib/pyexpat/__init__.pyi b/stdlib/pyexpat/__init__.pyi index 806db63693b5..83841a226a53 100644 --- a/stdlib/pyexpat/__init__.pyi +++ b/stdlib/pyexpat/__init__.pyi @@ -33,7 +33,8 @@ class XMLParserType: # Added in Python 3.10.20, 3.11.15, 3.12.3, 3.13.10, 3.14.1 def SetAllocTrackerActivationThreshold(self, threshold: int, /) -> None: ... def SetAllocTrackerMaximumAmplification(self, max_factor: float, /) -> None: ... - if sys.version_info >= (3, 15): + if sys.version_info >= (3, 13): + # Added in Python 3.13.4, 3.14.6 def SetBillionLaughsAttackProtectionActivationThreshold(self, threshold: int, /) -> None: ... def SetBillionLaughsAttackProtectionMaximumAmplification(self, max_factor: float, /) -> None: ...