SEPURI-SAI-KRISHNA opened a new pull request, #71649:
URL: https://github.com/apache/airflow/pull/71649

   `MSGraphAsyncOperator` defers with `MSGraphTrigger` from two places. The 
initial defer in
   `execute` passes the full request configuration. The pagination defer in
   `trigger_next_link`, used for every `@odata.nextLink` page after the first, 
leaves out
   `headers`, `data` and `scopes`:
   
   ```python
   self.defer(
       trigger=MSGraphTrigger(
           url=url,
           method=self.method,
           query_parameters=query_parameters,
           response_type=self.response_type,
           conn_id=self.conn_id,
           ...
       ),
   )
   ```
   
   All three default to `None` on the trigger, and `MSGraphTrigger.run()` uses 
them directly
   when issuing the request, so nothing restores them. Page 1 is sent as 
configured and every
   subsequent page is not.
   
   The clearest symptom of the inconsistency is that `method` *is* forwarded. 
An operator
   configured with a `POST` and a body therefore re-issues that `POST` on page 
2 with
   `data=None` — the verb is preserved while its body is dropped.
   
   `headers` matters for the same reason in ordinary use: Microsoft Graph 
requires
   `ConsistencyLevel: eventual` for `$count` and `$search` queries, so a query 
that works on
   the first page can start failing or returning inconsistent results partway 
through
   pagination. `scopes` feeds token acquisition, so follow-up pages could 
authenticate with
   different permissions than the first.
   
   `path_parameters` and `url_template` are deliberately left out of this 
change. They exist
   to build a URL, and pagination already has an absolute `nextLink`, so not 
forwarding them
   is correct rather than an oversight.
   
   No newsfragment: this is a provider change, and provider changelogs are 
regenerated from
   `git log` by the release manager.
   
   ---
   
   ##### Was generative AI tooling used to co-author this PR?
   
   - [X] Yes — Claude Code (Opus 5)
   
   Generated-by: Claude Code (Opus 5) 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