From d02be10cc75f30a0319bfb608971e7d691047549 Mon Sep 17 00:00:00 2001 From: Jelle Zijlstra Date: Mon, 10 Oct 2022 17:32:20 -0700 Subject: [PATCH 1/2] gh-98172: Fix formatting in `except*` docs --- Doc/reference/compound_stmts.rst | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/Doc/reference/compound_stmts.rst b/Doc/reference/compound_stmts.rst index d914686c0a1ad9..899ed4faf8a143 100644 --- a/Doc/reference/compound_stmts.rst +++ b/Doc/reference/compound_stmts.rst @@ -365,16 +365,16 @@ one :keyword:`!except*` clause, the first that matches it. :: +------------------------------------ >>> - Any remaining exceptions that were not handled by any :keyword:`!except*` - clause are re-raised at the end, combined into an exception group along with - all exceptions that were raised from within :keyword:`!except*` clauses. - - An :keyword:`!except*` clause must have a matching type, - and this type cannot be a subclass of :exc:`BaseExceptionGroup`. - It is not possible to mix :keyword:`except` and :keyword:`!except*` - in the same :keyword:`try`. - :keyword:`break`, :keyword:`continue` and :keyword:`return` - cannot appear in an :keyword:`!except*` clause. +Any remaining exceptions that were not handled by any :keyword:`!except*` +clause are re-raised at the end, combined into an exception group along with +all exceptions that were raised from within :keyword:`!except*` clauses. + +An :keyword:`!except*` clause must have a matching type, +and this type cannot be a subclass of :exc:`BaseExceptionGroup`. +It is not possible to mix :keyword:`except` and :keyword:`!except*` +in the same :keyword:`try`. +:keyword:`break`, :keyword:`continue` and :keyword:`return` +cannot appear in an :keyword:`!except*` clause. .. index:: From dbc065da27884855f597a54c43d3e8b0633a5d78 Mon Sep 17 00:00:00 2001 From: Jelle Zijlstra Date: Tue, 11 Oct 2022 07:33:13 -0700 Subject: [PATCH 2/2] remove stray >>> --- Doc/reference/compound_stmts.rst | 1 - 1 file changed, 1 deletion(-) diff --git a/Doc/reference/compound_stmts.rst b/Doc/reference/compound_stmts.rst index 899ed4faf8a143..8963481836431b 100644 --- a/Doc/reference/compound_stmts.rst +++ b/Doc/reference/compound_stmts.rst @@ -363,7 +363,6 @@ one :keyword:`!except*` clause, the first that matches it. :: +-+---------------- 1 ---------------- | ValueError: 1 +------------------------------------ - >>> Any remaining exceptions that were not handled by any :keyword:`!except*` clause are re-raised at the end, combined into an exception group along with