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

Only IOS: ImageEditor.cropImage method writeToFileError Code=101 "(null)" #52

Closed
sperko00 opened this issue Dec 3, 2019 · 2 comments
Closed

Comments

@sperko00
Copy link

sperko00 commented Dec 3, 2019

Bug

Bug is only happening on ios platform.
When calling cropImage method it gives this error (not always):
image

Environment info

React native info output:

System:
OS: macOS 10.15.1
CPU: (4) x64 Intel(R) Core(TM) i5-7360U CPU @ 2.30GHz
Memory: 18.79 MB / 8.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 10.16.3 - /usr/local/bin/node
Yarn: 1.19.1 - /usr/local/bin/yarn
npm: 6.9.0 - /usr/local/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
SDKs:
iOS SDK:
Platforms: iOS 13.2, DriverKit 19.0, macOS 10.15, tvOS 13.2, watchOS 6.1
Android SDK:
API Levels: 25, 28, 29
Build Tools: 28.0.3, 29.0.2
System Images: android-27 | Google APIs Intel x86 Atom, android-28 | Google APIs Intel x86 Atom, android-29 | Google APIs Intel x86 Atom
IDEs:
Android Studio: 3.5 AI-191.8026.42.35.5977832
Xcode: 11.2.1/11B500 - /usr/bin/xcodebuild
npmPackages:
react: 16.8.6 => 16.8.6
react-native: 0.60.3 => 0.60.3
npmGlobalPackages:
react-native-cli: 2.0.1

Library version: 2.2.0

Steps To Reproduce

Try to crop image on ios

@weymanator
Copy link

@sperko00 This error appears when you set values for width or height less than or equals to zero

@sperko00 sperko00 closed this as completed Mar 4, 2020
@devym-37
Copy link

devym-37 commented Jun 8, 2023

  const uriPath = await ImageEditor.cropImage(originUri, {
    size: {
      width: file.node.image.width,
      height: file.node.image.height,
    },
    offset: {
      x: 0,
      y: 0,
    },
  });

I sometimes get an error message like this in my code.
"message":"{"code":"101","message":"Error Domain=org.reactnativecommunity.imageeditor.writeToFileError Code=101 \"(null)\"","domain":"org.reactnativecommunity.imageeditor.writeToFileError .
Is there a problem with the code ? The file object is the information coming from the image file accessed by @react-native-camera-roll/camera-roll.

@weymanator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants