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

Fix unhandled exception in NAA JS Runtime scenario #7475

Merged
merged 5 commits into from
Jan 14, 2025

Conversation

codexeon
Copy link
Collaborator

There were regressions to the NAA JS Runtime scenario by the following commits, adding new platform API dependencies in the NAA critical path. This change is tested to get JS Runtime back into a working state.

Copy link
Contributor

Reminder: This PR appears to be stale. If this PR is still a work in progress please mark as draft.

@microsoft-github-policy-service microsoft-github-policy-service bot added Needs: Attention 👋 Awaiting response from the MSAL.js team and removed Needs: Attention 👋 Awaiting response from the MSAL.js team labels Jan 6, 2025
@codexeon codexeon force-pushed the dasau/jsruntime_exception_fix branch from fbdec53 to c7b2955 Compare January 11, 2025 08:14
@@ -56,12 +54,6 @@ export function validateCryptoAvailable(): void {
if (!window.crypto) {
throw createBrowserAuthError(BrowserAuthErrorCodes.cryptoNonExistent);
}
if (!window.crypto.subtle) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Not sure it we can safely remove this check as crypto.subtle is widely used in BrowserCrypto. cc @tnorling

Copy link
Member

@sameerag sameerag left a comment

Choose a reason for hiding this comment

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

@tnorling assuming you are okay with this.

@codexeon codexeon force-pushed the dasau/jsruntime_exception_fix branch from 7a9678c to b0af4d9 Compare January 13, 2025 23:36
@hectormmg hectormmg merged commit 585ed9e into dev Jan 14, 2025
7 checks passed
@hectormmg hectormmg deleted the dasau/jsruntime_exception_fix branch January 14, 2025 18:36
hectormmg added a commit that referenced this pull request Jan 14, 2025
To prevent regressions, add a test that simulates JS Runtime environment
and tests E2E scenario for NAA. This will fail until
#7475
is merged.

---------

Co-authored-by: Hector Morales <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
msal-browser Related to msal-browser package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants