Unintended Breaking Change Introduced in Python Library v1.5.0 #2301
Closed
singhk97
announced in
Announcements
Replies: 1 comment
-
|
We're clearing discussions and starting fresh. This discussion has not been acted upon. Please reopen the discussion, or start a new one if this question is still important. Thank you for your understanding. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
In version 1.5 release of the Python library, the following change was introduced to the
AssistantPlanner:@staticmethod async def create_assistant( - api_key: str, + api_key: Optional[str], + azure_ad_token_provider: Optional[Callable[..., str]], api_version: Optional[str], organization: Optional[str], endpoint: Optional[str], request: AssistantCreateParams, ) -> Assistant: ... # implementationThe addition of the
azure_ad_token_providerparameter to the middle of the parameters list changes the public api and is a breaking change. This was done under the assumption that theAssistantPlannerclass is under preview (like the JS, .NET counterparts), however that's not the case in the Python library.If you were using this method in your library in the following way.
The appropriate fix for it would be to change it to:
In hindsight it would've been a better idea to make the parameters strictly keyword arguments to avoid this clunky solution. This would unfortunately be a breaking change, and hence is not a viable option for now.
Beta Was this translation helpful? Give feedback.
All reactions