https://github.com/python/cpython/commit/2404cd94603bc585e617f0544e34560fa15b2713
commit: 2404cd94603bc585e617f0544e34560fa15b2713
branch: 3.13
author: Miss Islington (bot) <[email protected]>
committer: AlexWaygood <[email protected]>
date: 2024-05-25T17:30:57Z
summary:

[3.13] gh-99180: Make `StackSummary.should_show_carets` private (GH-119554) 
(#119556)

Co-authored-by: Alex Waygood <[email protected]>

files:
M Lib/traceback.py

diff --git a/Lib/traceback.py b/Lib/traceback.py
index 280d92d04cac9b..6ee1a50ca6804a 100644
--- a/Lib/traceback.py
+++ b/Lib/traceback.py
@@ -580,7 +580,7 @@ def format_frame_summary(self, frame_summary, **kwargs):
                 show_carets = False
                 with suppress(Exception):
                     anchors = _extract_caret_anchors_from_line_segment(segment)
-                show_carets = self.should_show_carets(start_offset, 
end_offset, all_lines, anchors)
+                show_carets = self._should_show_carets(start_offset, 
end_offset, all_lines, anchors)
 
                 result = []
 
@@ -694,7 +694,7 @@ def output_line(lineno):
 
         return ''.join(row)
 
-    def should_show_carets(self, start_offset, end_offset, all_lines, anchors):
+    def _should_show_carets(self, start_offset, end_offset, all_lines, 
anchors):
         with suppress(SyntaxError, ImportError):
             import ast
             tree = ast.parse('\n'.join(all_lines))

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-checkins.python.org/
Member address: [email protected]

Reply via email to