Closed carloslibardo closed 2 years ago
I have this problem too! Though I'm running ./gradlew assembleRelease
. Been going in circles for the past few days. Been trying to use these solutions, but nothing works.
https://github.com/Microsoft/react-native-code-push/issues/1427
Also, I find it interesting that this task is skipped in debug builds. I'd think if we set this flag bundleInRelease: false
the behavior would be the same since bundleInDebug defaults to false.
Here's my info:
Gradle: 6.2 Gradle Plugin: 3.5.3 React Native: 63.2
I've been able to find a workout around for now! @carloslibardo I'm also starting from a fresh build and using AppCenter. Just before I run my build, I manually create the folders that this task is looking for via a script.
- script: 'mkdir -p android/app/build/generated/res/react/release android/app/build/generated/assets/react/release'
This unblocked the task and I was able to finish the build.
I still find it interesting though that's the task isn't skipped like it does for debug builds when we set bundleInRelease: false
@jessamp i did that and it's work, i just don't know if have some problem because from natural way is not an empty folder, some assets are placed there.
My fear was that not will work correctly, but for now it's good.
Yeah I know what you mean. Hopefully this problem will be addressed correctly. But it's nice to get unblocked for now!
any solution ui have a same problum....nothing work for me
There's a workaround to create those directories via a patch file in the codepush.gradle
Not sure why a pr hasn't yet open with those 2 lines?
This issue has been automatically marked as stale because it has not had any activity for 60 days. It will be closed if no further activity occurs within 15 days of this comment.
This issue will now be closed because it hasn't had any activity for 15 days after stale. Please feel free to open a new issue if you still have a question/issue or suggestion.
Still have this issue on v7.0.5
. The workaround of creating an empty dir works, but it's not a completely desirable fix.
Still have this issue on v8.0.0
. Even the workaround does not work.
Also having the issue on v8.1.0 and the workaround does not work. @sleaper did you find any solution ?
For some reasons i don't have src with my js files folder, but i have the index.android.bundle generated from js files.
Then in my app/build.gradle i have this flag bundleInRelease: false, this means that bundle.js and generated folder don't will be created.
I already tried to manually create this folder, but i'm using appcenter build service and before run generateBundledResourcesHashRelease the Task :app:clean clean and remove this folder, i already tried to create folder with sudo to avoid remove it, but then the clean task fail.
I don't know what do, i found some issues about that and tried to copy these solutions, but without success, if someone can help me i will be very happy =)
Steps to Reproduce
Expected Behavior
Build & run on Android without errors
Actual Behavior
The build fails with the following message:
Reproducible Demo
Examples
folder runnode create-app.js appName react-native@0.61.5 react-native-code-push@6.0.0
command to generate plain CodePushified React Native app. Please see description on top ofcreate-app.js
file content if neededEnvironment