Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,6 @@ abstract class GenerateEntryPointTask : DefaultTask() {
import com.facebook.react.soloader.OpenSourceMergedSoMapping;
import com.facebook.soloader.SoLoader;

import java.io.IOException;

/**
* This class is the entry point for loading React Native using the configuration
* that the users specifies in their .gradle files.
Expand All @@ -87,11 +85,7 @@ abstract class GenerateEntryPointTask : DefaultTask() {
*/
public class ReactNativeApplicationEntryPoint {
public static void loadReactNative(Context context) {
try {
SoLoader.init(context, OpenSourceMergedSoMapping.INSTANCE);
} catch (IOException error) {
throw new RuntimeException(error);
}
Comment on lines -90 to -94

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Why are you removing this try/catch?

@shamilovtim shamilovtim Nov 6, 2026 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

SoLoader 0.13.0 changed that particular init overload so it no longer declares throws IOException.

https://github.com/meta/SoLoader/blob/v0.13.0/java/com/facebook/soloader/SoLoader.java#L366-L374

Previously, React Native caught IOException and wrapped it in RuntimeException. Now SoLoader does that itself on the inside for this particular overload.

SoLoader.init(context, OpenSourceMergedSoMapping.INSTANCE);

if ({{packageName}}.BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
DefaultNewArchitectureEntryPoint.load();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,6 @@ class GenerateEntryPointTaskTest {
import com.facebook.react.soloader.OpenSourceMergedSoMapping;
import com.facebook.soloader.SoLoader;

import java.io.IOException;

/**
* This class is the entry point for loading React Native using the configuration
* that the users specifies in their .gradle files.
Expand All @@ -70,11 +68,7 @@ class GenerateEntryPointTaskTest {
*/
public class ReactNativeApplicationEntryPoint {
public static void loadReactNative(Context context) {
try {
SoLoader.init(context, OpenSourceMergedSoMapping.INSTANCE);
} catch (IOException error) {
throw new RuntimeException(error);
}
SoLoader.init(context, OpenSourceMergedSoMapping.INSTANCE);

if (com.facebook.react.BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
DefaultNewArchitectureEntryPoint.load();
Expand Down
2 changes: 1 addition & 1 deletion packages/react-native/gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ nexus-publish = "2.0.0"
okhttp = "4.9.2"
okio = "2.9.0"
robolectric = "4.15.1"
soloader = "0.12.1"
soloader = "0.13.0"
uiautomator = "2.3.0"
xstream = "1.4.20"
yoga-proguard-annotations = "1.19.0"
Expand Down
Loading