mirror of
https://github.com/home-assistant/core.git
synced 2025-07-18 18:57:06 +00:00
Add comment about error assigning in frame.report_usage (#148105)
This commit is contained in:
parent
4be2e84ce6
commit
99d63c49bb
@ -193,6 +193,11 @@ def report_usage(
|
|||||||
exclude_integrations=exclude_integrations
|
exclude_integrations=exclude_integrations
|
||||||
)
|
)
|
||||||
except MissingIntegrationFrame as err:
|
except MissingIntegrationFrame as err:
|
||||||
|
# We need to be careful with assigning the error here as it affects the
|
||||||
|
# cleanup of objects referenced from the stack trace as seen in
|
||||||
|
# https://github.com/home-assistant/core/pull/148021#discussion_r2182379834
|
||||||
|
# When core_behavior is ReportBehavior.ERROR, we will re-raise the error,
|
||||||
|
# so we can safely assign it to integration_frame_err.
|
||||||
if core_behavior is ReportBehavior.ERROR:
|
if core_behavior is ReportBehavior.ERROR:
|
||||||
integration_frame_err = err
|
integration_frame_err = err
|
||||||
_report_usage_partial = functools.partial(
|
_report_usage_partial = functools.partial(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user