Closed rnqayush closed 2 years ago
@rnqayush I think this error is not from the compressor package. i think it is from https://github.com/uuidjs/uuid#getrandomvalues-not-supported
can you provide reproducible example repo? so I can see it
@nomi9995 thanks for you response, actually i have tested this after removing this video compressor code then it works fine but after implementing this code i get this error.
@nomi9995 i made a fresh react native project and then installed this package. unfortunately i am getting error kindly look on it and suggest some idea to resolve it. also i am sharing the github repo. GitHub: https://github.com/rnqayush/react-native-video-compressor
snapshot of error:
@rnqayush Actually this is due to jcenter, many libraries which were published on jcenter having this issue. we should have to publish all libraries to mavenCenter. I will create a ticket on mavenCenter
so our library may not be down
https://developer.android.com/studio/build/jcenter-migration
@nomi9995 thanks a lot for your response, kindly let us know when it is expected to be updated.
@rnqayush actually I did not publish the library on mavenCenter before. I am going to make a ticket on mavenCenter and then d that the community will review the ticket and then will publish or reject it. it depends on the community review.
@nomi9995 sure thankyou .
also @nomi9995 do it will work on ios or there too it can have issues.
@rnqayush it is specifically for android
@rnqayush can you try 0.5.3-rc.0
version. it is working on my side
I am also facing same issue with "react-native-compressor": 0.5.3 and react-native: 0.64.2
[Error: crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported]
@ymane can you provide reproducible example in git repo because it is not reproducing on my side
@rnqayush @ymane I just release 1.0.0
can you try the 1.0.0
version
yarn add react-native-compressor@1.0.0
i have same issue
@moowoonsunghoon can you tell me your RN version and compressor version?
@nomi9995
my version is
react-native: 0.64.1
react-native-compressor: 1.0.1
@moowoonsunghoon sorry for that. react-native-compressor>=1.0.0 is for react-native@0.65
you can use 0.5.6
version for the compressor
yarn add react-native-compressor@0.5.6
after this please do Invalidate Caches / Restart
from android studio
@moowoonsunghoon i will update documentation soon
@nomi9995 it's working!! thank you!!
Hello! Same issue on iOS. React Native version: 0.66.2 React Native Compressor: 1.0.2
@DavidGonzalezGutierrez can you try this Invalidate Caches / Restart
from android studio
Yes, but is in iOS. I clean the build folder in Xcode, and the caches of metro. But, when I try to compress a video I recieve the error crypto.getRandomValues() not supported.
When I use UUID version 4 in my app, I always use with DEV because I read the uuidv4 has problems in development mode
@DavidGonzalezGutierrez can you try this solution https://github.com/uuidjs/uuid/issues/416#issuecomment-651294527
import 'react-native-get-random-values';
in index.js or App.js file
let know if it fixes it. I will make this one as a part of this package
Yes, It works!
@DavidGonzalezGutierrez I also have published a new version 1.0.3
of the compressor where I added above fix
Nice work!
@nomi9995 Hello, When I use minimumFileSizeForCompress in video it changes the file format and didn't upload with the error TypeError: Network request failed "react-native-compressor": "^0.5.17", "react-native": "0.64.2", It perfectly works on images but didn't work on video
Compress video is not working on android
Hi I am using "react-native": "0.70.1" and "react-native-compressor": "^1.7.2". Getting error in build-
Could not resolve all task dependencies for configuration ':react-native-compressor:debugCompileClasspath'. Could not find com.github.numandev1:VideoCompressor:1a262bba37. Required by: project :react-native-compressor
@avyasradicle can you try this code and try to run project
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
It worked. Thank you!! :)
1-earlier i was using react native 0.61.5 and used this library for video and image compression. it was working as expected. 2- I have upgraded react native version to 0.65.1 and now image compression is working as expected but in video compression i am having errors. 3- i am sharing the screenshot of my code and error kindly suggest some idea to resolve it.
![toshob](https://user-images.githubusercontent.com/74084740/133382823-6e63e595-76d0-456a-a088-2fe13994596b.PNG)