forcedotcom / SalesforceMobileSDK-Android

Android SDK for Salesforce
Other
339 stars 384 forks source link

@W-15548296: [MSDK Android] NetworkOnMainThreadException In App Created From Hybrid Local Template #2552

Closed JohnsonEricAtSalesforce closed 2 months ago

JohnsonEricAtSalesforce commented 2 months ago

🎸 Ready For Review 🥁

This resolves a network on main thread exception that I discovered in the hybrid template apps.

This is interesting in that the call to getMyDomainAuthConfig is happening in a different location than it does in SalesforceSDKManager.fetchAuthenticationConfiguration with very subtly different logic. The key difference is that the hybrid app doesn't call setBrowserLoginEnabled when the authorization config is obtained. @brandonpage - Any chance you know why that is? It looks intentional downstream in isSamlLoginRedirect.

Perhaps in the future the switch around setBrowserLoginEnabled could be added to the SalesforceSdkManager version so redundancy is reduced.

mobilesdk-bot commented 2 months ago
1 Error
:no_entry_sign: Tests have failed, see below for more information.
1 Warning
:warning: No Lint Results.

Tests:

Name Classname Time
test[testRestEndpoint] com.salesforce.androidsdk.phonegap.ForceJSTest 0.004

Tests results for SalesforceHybrid

Generated by :no_entry_sign: Danger

mobilesdk-bot commented 2 months ago
1 Error
:no_entry_sign: Tests have failed, see below for more information.

Tests:

Name Classname Time
testDecryptDataEncryptedWithNewRSACipherForKeyCreatedBeforeUpgrade com.salesforce.androidsdk.security.KeyStoreWrapperTest 0.082
testDecryptDataEncryptedWithNewRSACipher com.salesforce.androidsdk.security.KeyStoreWrapperTest 0.085
testRSAOAEPSHA256EncryptDecrypt com.salesforce.androidsdk.security.KeyStoreWrapperTest 0.055

Tests results for SalesforceSDK

Generated by :no_entry_sign: Danger