SameerMesiah97 opened a new pull request, #61640: URL: https://github.com/apache/airflow/pull/61640
**Description** This change improves the clarity and intent of `find_spark_job` and its tests: * Made the comments and docstring for `find_spark_job` more explicit about pod selection and prioritization rules. * Repurposed `test_find_spark_job_picks_running_pod` to assert that only non-terminating pods are eligible for selection. * Tightened `test_find_spark_job_picks_pending_pod` to validate phase-based selection only, without relying on `deletion_timestamp`. * Simplified `test_find_spark_job_picks_succeeded` by removing terminating pods and focusing solely on phase ordering. * Simplified `test_find_spark_job_picks_latest_pod` by neutralizing pod phases to isolate creation timestamp–based selection. **Rationale** `find_spark_job` implements subtle but critical logic used during restarts and retries. This cleanup reduces ambiguity, documents intent directly in tests, and makes the selection logic easier to maintain and review while preserving existing semantics. -- 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]
