Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clean up the use of rest_version #719

Open
vchudnov-g opened this issue Oct 2, 2024 · 0 comments
Open

clean up the use of rest_version #719

vchudnov-g opened this issue Oct 2, 2024 · 0 comments
Assignees
Labels
priority: p2 Moderately-important priority. Fix may not be included in next release. type: cleanup An internal cleanup or hygiene concern.

Comments

@vchudnov-g
Copy link
Contributor

rest_version is used to convey information about our REST implementation, and we populate it with versions of the dependencies we use in REST. We should either create a static string that we always send in all requests (for example, including the versions of requests and of auth, even though eg REST sync and REST async only use a different one of those); or we should include only the versions of the dependencies relevant for a given call (eg requests for REST sync and auth for REST async). I would favor the former.

The format of rest_value should label which libraries the version numbers we're providing apply to. So I propose a format like rest_version="requests@1.2.3,auth@4.5.6".

Internally, we may want to implement rest_versions as a dictionary of library name to version string. And then in client_info.py, we can serialize the dictionary into the agreed format, such as the one I propose in the paragraph above. The advantage of this is that each module can independently add the dependencies it relies on, rather than us having to do it in a centralized place. This more moredular and scalable.

@vchudnov-g vchudnov-g added type: cleanup An internal cleanup or hygiene concern. priority: p2 Moderately-important priority. Fix may not be included in next release. labels Oct 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: p2 Moderately-important priority. Fix may not be included in next release. type: cleanup An internal cleanup or hygiene concern.
Projects
None yet
Development

No branches or pull requests

2 participants