-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Open
Description
Overview
I want to crop an image using openCropper, but I encounter the following error:
[Error: file]
E_NO_IMAGE_DATA_FOUND
The error only occurs on Android devices with the latest security patches applied.
Affected Device
The error only occurs on the following device:
- Android Pixel 8a
- Version 16
- Latest security patches applied
This error does not occur on iOS.
Source
try {
console.log("path", photo.path);
const croppedImage = await ImageCropPicker.openCropper({
path: photo.path,
width: image.width,
height: image.height,
cropping: true,
mediaType: "photo",
cropperCircleOverlay: false,
freeStyleCropEnabled: false,
includeBase64: false,
includeExif: false,
cropperRotateButtonsHidden: true,
cropperChooseText: "OK",
cropperCancelText: "CANCEL",
cropperToolbarTitle: "CROP",
hideBottomControls: true,
showCropGuidelines: false,
cropperChooseColor: "#ffffff",
cropperCancelColor: "007AFF",
});
setImage({
uri: croppedImage.path,
width: croppedImage.width,
height: croppedImage.height,
fileName: image.fileName,
type: "image",
});
} catch (error) {
console.log("=== エラー詳細 ===");
console.log("error:", error);
console.log("error.message:", (error as any).message);
console.log("error.code:", (error as any).code);
console.log("typeof error:", typeof JSON.stringify(error));
console.log("JSON:", JSON.stringify(error));
}The image is in jpeg format
JJSLIoTJJSLIoT
Metadata
Metadata
Assignees
Labels
No labels