Skip to content

Add RequestCallerInfo data object to RequestsTransport.request - #1261

Merged
m1yag1 merged 7 commits into
4.x-devfrom
sc-43037-caller-info
Jul 17, 2025
Merged

Add RequestCallerInfo data object to RequestsTransport.request#1261
m1yag1 merged 7 commits into
4.x-devfrom
sc-43037-caller-info

Conversation

@m1yag1

@m1yag1 m1yag1 commented Jul 16, 2025

Copy link
Copy Markdown
Contributor

sc-43037
This adds RequestCallerInfo as an extensible container for caller context information in RequestsTransport.request().

The change breaks backward compatibility and replaces the authorizer parameter while enabling future extensions for additional caller context beyond authorization.

RequestCallerInfo takes precedence when both parameters are provided, with a warning logged for conflicting usage.


📚 Documentation preview 📚: https://globus-sdk-python--1261.org.readthedocs.build/en/1261/

* Add RequestCallerInfo class for passing caller context information
* Update RetryContext to use caller_info instead of authorizer
* Maintain backward compatibility with existing authorizer parameter
* Add warning when both caller_info and authorizer parameters differ

@sirosen sirosen left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The intent with that card, although I now see that I did not write it unambiguously, was that we replace authorizer with the new caller info object. Could you update to do so? The lack of a need for backwards compatibility in v4 is why we benefit from doing this now, in particular.

Comment thread src/globus_sdk/transport/_clientinfo.py Outdated
Comment thread src/globus_sdk/transport/requests.py Outdated

@MaxTueckeGlobus MaxTueckeGlobus left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just want to quick make a note of this for now, I'll hold off on the main body of my review until Stephen's feedback has been resolved.

Comment thread changelog.d/20250716_105609_8730430+m1yag1_sc_43037_caller_info.rst
Comment thread src/globus_sdk/transport/requests.py Outdated
m1yag1 and others added 2 commits July 17, 2025 14:46
This removes backward compatibility and makes caller_info a required parameter
based on PR review feedback. Moves RequestCallerInfo to requests.py.
Comment thread tests/unit/transport/test_transport_authz_handling.py
Comment thread src/globus_sdk/transport/retry.py Outdated
@m1yag1
m1yag1 force-pushed the sc-43037-caller-info branch from 327e443 to 72a03c8 Compare July 17, 2025 20:13
@m1yag1
m1yag1 merged commit 28b422c into 4.x-dev Jul 17, 2025
7 checks passed
@m1yag1
m1yag1 deleted the sc-43037-caller-info branch July 17, 2025 20:57
@sirosen sirosen mentioned this pull request Oct 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants