I keep running into errors trying to build my project in ionic app flow, the android keeps failing.
app id
badge
Ionic ed140720
[02:11:36]: ▸ Build at: 2023-02-14T02:11:36.651Z - Hash: f5c5aa347eabcbc6 - Time: 81577ms
[02:11:36]: $ ionic info
[02:11:39]: ▸ Ionic:
[02:11:39]: ▸ Ionic CLI : 6.18.0 (/usr/local/nvm/versions/node/v16.13.2/lib/node_modules/@ionic/cli)
[02:11:39]: ▸ Ionic Framework : @ionic/angular 6.5.1
[02:11:39]: ▸ @angular-devkit/build-angular : 15.1.3
[02:11:39]: ▸ @angular-devkit/schematics : 15.1.3
[02:11:39]: ▸ @angular/cli : 15.1.3
[02:11:39]: ▸ @ionic/angular-toolkit : 6.1.0
[02:11:39]: ▸ Capacitor:
[02:11:39]: ▸ Capacitor CLI : 4.6.2
[02:11:39]: ▸ @capacitor/android : 4.6.2
[02:11:39]: ▸ @capacitor/core : 4.6.2
[02:11:39]: ▸ @capacitor/ios : 4.6.2
[02:11:39]: ▸ Utility:
[02:11:39]: ▸ cordova-res : not installed globally
[02:11:39]: ▸ native-run : 1.7.1
[02:11:39]: ▸ System:
[02:11:39]: ▸ NodeJS : v16.13.2 (/usr/local/nvm/versions/node/v16.13.2/bin/node)
[02:11:39]: ▸ npm : 9.4.2
[02:11:39]: ▸ OS : Linux 5.4
[02:11:39]: Generating app manifest…
[02:11:39]: $ ionic deploy manifest
[02:11:41]: ▸ [OK] Appflow Deploy manifest written to ./www/pro-manifest.json!
[02:11:41]: -----------------------------------------
[02:11:41]: — Step: get_cap_android_project_dir —
[02:11:41]: -----------------------------------------
[02:11:41]: ---------------------------
[02:11:41]: — Step: set_java_home —
[02:11:41]: ---------------------------
[02:11:41]: Try to detect the android gradle plugin version
[02:11:42]: Project Android Gradle Plug-in major version is 7: set Java to 11
[02:11:42]: ----------------------
[02:11:42]: — Step: cap_sync —
[02:11:42]: ----------------------
[02:11:42]: $ npx cap sync android
[02:11:44]: ▸ Copying web assets from www to android/app/src/main/assets/public in 676.17ms
[02:11:44]: ▸ Creating capacitor.config.json in android/app/src/main/assets in 954.28μs
[02:11:44]: ▸ copy android in 749.41ms
[02:11:44]: ▸ Updating Android plugins in 13.98ms
[02:11:44]: ▸ [info] Found 4 Capacitor plugins for android:
[02:11:44]: ▸ @capacitor/app@4.1.1
[02:11:44]: ▸ @capacitor/haptics@4.1.0
[02:11:44]: ▸ @capacitor/keyboard@4.1.1
[02:11:44]: ▸ @capacitor/status-bar@4.1.1
[02:11:44]: ▸ update android in 61.10ms
[02:11:44]: ▸ [info] Sync finished in 0.815s
[02:11:44]: -------------------------------
[02:11:44]: — Step: cap_custom_deploy —
[02:11:44]: -------------------------------
[02:11:44]: No custom native config detected.
[02:11:44]: Building android…
[02:11:44]: ----------------------------------
[02:11:44]: — Step: modify_gradle_config —
[02:11:44]: ----------------------------------
[02:11:44]: No custom native config found… skipping
[02:11:44]: -------------------------
[02:11:44]: — Step: bundledebug —
[02:11:44]: -------------------------
[02:11:45]: ▸ Error: Could not find or load main class org.gradle.wrapper.GradleWrapperMain
[02:11:45]: ▸ Caused by: java.lang.ClassNotFoundException: org.gradle.wrapper.GradleWrapperMain
[02:11:45]: -------------------------
[02:11:45]: — Step: upload_logs —
[02:11:45]: -------------------------
±---------------------------±--------------------+
| Lane Context |
±---------------------------±--------------------+
| DEFAULT_PLATFORM | ios |
| PLATFORM_NAME | android |
| LANE_NAME | android build_ionic |
| NODE_PACKAGE_MANAGER | npm |
| PROJECT_WEB_DIR | www |
| DOWNLOAD_CREDENTIAL_EXISTS | false |
| GRADLE_BUILD_TYPE | debug |
±---------------------------±--------------------+
[02:11:50]: Shell command exited with exit status 1 instead of 0.
Error: Could not find or load main class org.gradle.wrapper.GradleWrapperMain
Caused by: java.lang.ClassNotFoundException: org.gradle.wrapper.GradleWrapperMain
/usr/local/bundle/bin/fastlane: \e[31m[!] Shell command exited with exit status 1 instead of 0. (FastlaneCore::Interface::FastlaneShellError)
Error: Could not find or load main class org.gradle.wrapper.GradleWrapperMain
Caused by: java.lang.ClassNotFoundException: org.gradle.wrapper.GradleWrapperMain
\e[0m
±-----±---------------------------------------±------------+
| fastlane summary |
±-----±---------------------------------------±------------+
| Step | Action | Time (in s) |
±-----±---------------------------------------±------------+
| 1 | add_extra_platforms | 0 |
| 2 | default_platform | 0 |
| 3 | build_summary | 1 |
| 4 | detect_native_type | 0 |
| 5 | Switch to android build_capacitor lane | 0 |
| 6 | detect_package_manager | 0 |
| 7 | add_git_credentials | 0 |
| 8 | get_appflow_config | 0 |
| 9 | dependency_install | 56 |
| 10 | create_capacitor_config | 0 |
| 11 | get_web_dir | 0 |
| 12 | modify_cap_web_config | 0 |
| 13 | download_credential | 0 |
| 14 | build_pro_app | 91 |
| 15 | get_cap_android_project_dir | 0 |
| 16 | set_java_home | 0 |
| 17 | cap_sync | 2 |
| 18 | cap_custom_deploy | 0 |
| 19 | modify_gradle_config | 0 |
| | bundledebug | 0 |
| 21 | upload_logs | 5 |
±-----±---------------------------------------±------------+
[02:11:50]: fastlane finished with errors
Running after script…
$ run “clean-up”
ERROR: Job failed: command terminated with exit code 1https://bitbucket.org/quaketechs/badge6/src/master/