create-miniapp is stuck at creating project step
I runned npm install -g electrode-native successfully. After that I create a new folder cd into it and run "ern create-miniapp MovieListMiniApp" and it was stuck at creating project step. Here is the output
ern create-miniapp MovieListMiniApp
| | |_ | | _ _ ___ | | | | |__ | |() _____
| || / -) | | '/ _ / / -_) | . / ` | | \ V / -)
||____|_|| _/_,_| ||__,|_|_|_/___|
[v0.53.7] [Cauldron: -NONE-]
✔ Ensuring that Electrode Native module name is valid 0s ✔ Ensuring that Electrode Native module name is valid 0s ✔ Ensuring that npm package name is valid 0s ⠸ Creating MiniApp 18m 35s ✔ Retrieved react-native version from Manifest [0.77.2] 1s ✔ Syncing https://github.com/electrode-io/electrode-native-manifest.git Manifest 1s ⠹ Creating movielistminiapp project using [email protected] 18m 33s ^C
after 18m I forcefully left the process. When I looked at the folder it seemed like create-miniapp worked because there was a react native like project. but when I run " ern run-android" I got this output
ern run-android
| | |_ | | _ _ ___ | | | | |__ | |() _____
| || / -) | | '/ _ / / -_) | . / ` | | \ V / -)
||____|_|| _/_,_| ||__,|_|_|_/___|
[v0.53.7] [Cauldron: -NONE-]
✖ An error occurred: No ern section found in movielistminiapp package.json. Are you sure this is a MiniApp ?
This project looked exactly like what we need but it was a bummer it did not work. Hope to find a solution.
Hi @1hsyn1! Thanks for the report. I briefly checked locally and can confirm: It is also getting stuck for me.
The root cause appears to be an interactive prompt during the RN cli init call:
? Do you want to install CocoaPods now? Only needed if you run your project in Xcode directly › (y/N)
A proper fix will take some further investigation and might involve pinning the cli dependency to a certain version.
For now, to quickly get you unblocked, you can use the --skipInstall flag, which will cause the underlying tool to not ask that question in the first place:
ern create-miniapp --skipInstall erntest-miniapp
Thank you I'm able to pass this step but when I run "ern run-android" after "ern create-miniapp --skipInstall erntest-miniapp" I got this output :
ern run-android
___ _ _ _ _ _ _ _
| __| |___ __| |_ _ _ ___ __| |___ | \| |__ _| |_(_)_ _____
| _|| / -_) _| _| '_/ _ \/ _` / -_) | .` / _` | _| \ V / -_)
|___|_\___\__|\__|_| \___/\__,_\___| |_|\_\__,_|\__|_|\_/\___|
[v0.53.7] [Cauldron: -NONE-]
✔ Starting React Native Packager [http://localhost:8081] 0s
✔ Generating Composite locally 44s
✔ Generating Composite 44s
✔ Cleaning up existing composite directory 0s
✔ Adding extra packages to the composite 37s
✔ Syncing https://github.com/electrode-io/electrode-native-manifest.git Manifest 1s
✔ Starting React Native Packager [http://localhost:8081] 0s
ution failed for task ':app:checkDebugAarMetadata'.
✖ > Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
✖ > Failed to transform react-android-0.77.2-debug.aar (com.facebook.react:react-android:0.77.2) to match attributes {artifactType=android-aar-metadata, com.android.build.api.attributes.BuildTypeAttr=debug, org.gradle.category=library, org.gradle.depen
dency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
✖ > Execution failed for JetifyTransform: /Users/1hsyn1/.gradle/caches/modules-2/files-2.1/com.facebook.react/react-android/0.77.2/493ccf9c497492e5bd151dce6b31fbb270dc96b9/react-android-0.77.2-debug.aar.
✖ > Java heap space
✖
✖ * Try:
✖ > Run with --stacktrace option to get the stack trace.
✖ > Run with --info or --debug option to get more log output.
✖ > Run with --scan to get full insights.
✖ > Get more help at https://help.gradle.org.
✖
✖ BUILD FAILED in 5m 57s
Is this happening since we skipped install, do you think it is related? If it is not does this have a solution?
Hi @1hsyn1
Can you confirm what node and java versions you are using in your local?
You should be using exactly node 18 and JAVA 17 JDK to run this latest ern version.
Can you please try running this command first and re-run the ern run-android command after verifying above
ern platform config set logLevel trace