Skip to content

Conversation

@rayluo
Copy link
Contributor

@rayluo rayluo commented Sep 26, 2024

The lengthy discussion in "Updates to msal/application.py may now be out-of-sync with msal_extensions"
#745
considered a mitigation of introducing a new optional dependency msal[extensions] for MSAL. However, after offline discussion, we believe it has two drawbacks: (1) it is hardly discoverable for most msal-extensions users, and (2) it introduces a permanent "msal[extensions]" declaration only for trivial gain.

So, we ended up settling on an alternative. MSAL will now detect the msal-extensions from the current environment. If its version is lower than 1.2.0, MSAL will emit a warning like this:

/.../msal/application.py:203: UserWarning: Please upgrade msal-extensions. Only msal-extensions 1.2+ can work with msal 1.30+

This PR will close #745 .

CC @jiasli , @kcphila

@rayluo rayluo requested a review from a team as a code owner September 26, 2024 06:08
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Indeed. In fact, msal-extensions used to also use packaging.version but have since removed it in https://github.com/AzureAD/microsoft-authentication-extensions-for-python/pull/125.

Copy link
Contributor

Choose a reason for hiding this comment

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

Nice comment! Makes things clear.

@rayluo rayluo force-pushed the msal-extensions-check branch from 28af693 to bb6d872 Compare September 26, 2024 07:24
@rayluo rayluo merged commit bb6d872 into dev Sep 26, 2024
12 checks passed
@rayluo rayluo deleted the msal-extensions-check branch September 26, 2024 18:42
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.

[Bug] Updates to msal/application.py may now be out-of-sync with msal_extensions

3 participants