Description
PptxConverter crashes with AttributeError when a chart title has no text frame. According to python-pptx docs, chart_title.text_frame can be None if the title was set via the text property rather than through the rich text frame API.
Root Cause
In _pptx_converter.py line 239:
chart.chart_title.text_frame returns None in some cases (e.g., charts where the title was set programmatically), causing AttributeError: NoneType object has no attribute text.
Expected Behavior
Charts without a text frame on the title should be handled gracefully - the title should be skipped rather than crashing the entire conversion.
Proposed Fix
Add a None check: if chart.has_title and chart.chart_title.text_frame is not None
Description
PptxConverter crashes with AttributeError when a chart title has no text frame. According to python-pptx docs, chart_title.text_frame can be None if the title was set via the text property rather than through the rich text frame API.
Root Cause
In _pptx_converter.py line 239:
chart.chart_title.text_frame returns None in some cases (e.g., charts where the title was set programmatically), causing AttributeError: NoneType object has no attribute text.
Expected Behavior
Charts without a text frame on the title should be handled gracefully - the title should be skipped rather than crashing the entire conversion.
Proposed Fix
Add a None check: if chart.has_title and chart.chart_title.text_frame is not None