Open zadigus opened 1 week ago
Ok so apparently it's enough to change your MyClientAssertionCredential.get_token
method in file token_credential.py
like this
def get_token(self, *scopes, **kwargs):
# get the token using the application
# this is the change!
token = self.app.acquire_token_for_client(list(scopes))
if 'error' in token:
raise Exception(token['error_description'])
expires_on = time.time() + token['expires_in']
# return an access token with the token string and expiration time
return AccessToken(token['access_token'], int(expires_on))
Is your feature request related to a problem? Please describe.
I was looking to make this example working with the latest package versions for msal and azure-keyvault-secrets. Unfortunately, when I do so, I get the following error:
Describe the solution you'd like
I would like to know what changes I should make to your example so that it works with the latest versions of the azure-keyvault-secrets and msal libraries.
Describe alternatives you've considered
Keeping those versions pinned, but then I have conflicts with other packages I am using.
Additional context