From d95597ce8638c2cffc58575e3abfd26c8b031d9e Mon Sep 17 00:00:00 2001 From: Taha Yassine Kraiem Date: Fri, 28 Oct 2022 17:11:25 +0200 Subject: [PATCH] feat(chalice): debug sourcemaps.pye --- api/chalicelib/core/sourcemaps.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/api/chalicelib/core/sourcemaps.py b/api/chalicelib/core/sourcemaps.py index 31c8d884e..1cf598f01 100644 --- a/api/chalicelib/core/sourcemaps.py +++ b/api/chalicelib/core/sourcemaps.py @@ -148,8 +148,13 @@ MAX_COLUMN_OFFSET = 60 def fetch_missed_contexts(frames): source_cache = {} for i in range(len(frames)): - if len(frames[i]["context"]) > 0: - continue + try: + if len(frames[i]["context"]) > 0: + continue + except Exception: + print(">>>>>>>> fetch_missed_contexts exception:") + print(frames) + print("------------------") file_abs_path = frames[i]["frame"]["absPath"] if file_abs_path in source_cache: file = source_cache[file_abs_path]