Vamsi-klu commented on PR #66296: URL: https://github.com/apache/airflow/pull/66296#issuecomment-4888932342
Good catch, thanks! Fixed: the `finally` drop/commit is now wrapped so that when we're unwinding from a delete failure, a cleanup error is logged as a warning and the original delete error keeps propagating (Python otherwise makes the `finally`-raised error the top-level one). On the success path a drop/commit failure still surfaces normally. Added `test_do_delete_original_error_survives_archive_drop_failure` (failure path — original `IntegrityError` propagates even when the drop raises `OperationalError`) and `test_do_delete_success_propagates_archive_drop_error` (success path — drop error is not swallowed). No backend test since a real DROP failure can't be forced deterministically; the masking logic is fully covered by the mock tests. --- Drafted-by: Claude Code (Opus 4.8); reviewed by @Vamsi-klu before posting -- 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]
