shahar1 opened a new pull request, #68085:
URL: https://github.com/apache/airflow/pull/68085

   ### What
   
   Extends the language-gating logic from #67972 to cover `push`-to-main 
events, not just `pull_request`.
   
   The `detect-languages` job now uses the GitHub compare API to determine 
which languages actually changed in a push and builds the analysis matrix from 
that — the same way it already does for PRs.
   
   `schedule` runs are unchanged: they still scan all five languages to 
maintain full periodic coverage of the main branch.
   
   ### Why
   
   #67972 intentionally left `push`-to-main scanning all languages, reasoning 
that full coverage on `main` was the goal. However, `schedule` (daily at 02:00 
UTC) already provides that full-coverage guarantee. A docs-only or 
single-language merge commit to main no longer needs to fan out five CodeQL 
jobs.
   
   ### Edge cases handled
   
   - **Zero-SHA before** (`0000000000000000000000000000000000000000`): branch 
creation — falls back to all languages.
   - **Compare API failure** (network error, stale SHA): `|| true` prevents a 
hard failure; the empty-string guard then falls back to all languages.
   
   ### Behaviour summary
   
   | Event | Before | After |
   |---|---|---|
   | `pull_request` | changed languages only (#67972) | unchanged |
   | `push` to main | all 5 languages | changed languages only |
   | `schedule` | all 5 languages | all 5 languages (unchanged) |
   
   related: #67972
   
   ---
   
   ##### Was generative AI tooling used to co-author this PR?
   
   - [X] Yes — Claude Code (claude-sonnet-4-6)
   
   Generated-by: Claude Code (claude-sonnet-4-6) following [the 
guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions)
   


-- 
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]

Reply via email to