capture the stack trace properly

This commit is contained in:
Abi Raja 2024-06-27 12:33:55 +08:00
parent 5e00b406af
commit 1f9e93a2c7

View File

@ -13,7 +13,8 @@ def extract_html_content(text: str):
print( print(
"[HTML Extraction] No <html> tags found in the generated content: " + text "[HTML Extraction] No <html> tags found in the generated content: " + text
) )
sentry_sdk.capture_exception( try:
Exception(" No <html> tags found in the generated content") raise Exception("No <html> tags found in the generated content")
) except:
sentry_sdk.capture_exception()
return text return text