Closed DiaoMIngHero closed 8 months ago
I have the same problem. please solve
The easiest way to fix until prs are approved is to use patch-package to add those two errors in java like:
diff --git a/node_modules/react-native-create-thumbnail/android/src/main/java/com/createthumbnail/CreateThumbnailModule.java b/node_modules/react-native-create-thumbnail/android/src/main/java/com/createthumbnail/CreateThumbnailModule.java
index 9bd67d8..6188e43 100644
--- a/node_modules/react-native-create-thumbnail/android/src/main/java/com/createthumbnail/CreateThumbnailModule.java
+++ b/node_modules/react-native-create-thumbnail/android/src/main/java/com/createthumbnail/CreateThumbnailModule.java
@@ -168,7 +168,7 @@ public class CreateThumbnailModule extends ReactContextBaseJavaModule {
return dir;
}
- private static Bitmap getBitmapAtTime(Context context, String filePath, int time, Map headers) {
+ private static Bitmap getBitmapAtTime(Context context, String filePath, int time, Map headers) throws IOException, IllegalStateException {
MediaMetadataRetriever retriever = new MediaMetadataRetriever();
if (URLUtil.isFileUrl(filePath)) {
String decodedPath;
try { // Code that may throw an IOException retriever.release(); } catch (IOException e) { // Handle the IOException, you can log it or take appropriate actions. e.printStackTrace(); }
@souvik-ghosh Same problem here, preventing us running a new build.
"react-native": "0.72.1" "react-native-create-thumbnail": "1.6.4"
Tried '2.0.0-rc.2' but no luck there either.
@souvik-ghosh Same here with:
"react-native": "0.71.7" "react-native-create-thumbnail": "1.6.4"
try { // Code that may throw an IOException retriever.release(); } catch (IOException e) { // Handle the IOException, you can log it or take appropriate actions. e.printStackTrace(); }
this solved for me
Describe the bug![image](https://github.com/souvik-ghosh/react-native-create-thumbnail/assets/48375019/09f02e93-b33f-4884-9375-498b67be81a6)
To Reproduce 1.add dependency 2.run
Version
react-native-create-thumbnail
1.6.4Expected Results no exception
Snack, code example, screenshot, or link to a repository