kaxil commented on code in PR #73249:
URL: https://github.com/apache/airflow/pull/73249#discussion_r4031672116
##########
task-sdk/tests/task_sdk/execution_time/test_supervisor.py:
##########
@@ -1088,6 +1088,9 @@ def mock_monotonic():
False,
id="no_terminal_state",
),
+ pytest.param(None, None, 10, False, id="execution_still_running"),
+ pytest.param(None, 9.0, 10, True,
id="finalization_without_reported_state"),
Review Comment:
These pass `terminal_state=None` with `_task_end_time_monotonic` set, which
`_handle_request` can't produce: `_send_terminal_state_msg` sets
`_terminal_state` before the API call that can raise, so a real failure always
leaves it non-None. The behaviour holds (I checked both trees), but the
"finalization stays bounded when the first call fails" case has no test on the
path that delivers it. Same reason `finalization_started_at_zero` doesn't
isolate the zero-timestamp truthiness fix: the old `if not
self._terminal_state` guard returns first, so it would need a reported state
plus a zero `task_end_time_monotonic`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]