Bitrise Build Issue Report template
Description of the issue
I have an entry in my package.json file that loads a cordova plugin directly from github as the current npm release has issues. Locally this works fine but when trying to run Ionic Archive in Bitrise the step fails trying to retrieve the plugin.
package.json entry:
"cordova-plugin-file-transfer": "github:apache/cordova-plugin-file-transfer",
Error:
Discovered plugin "cordova-plugin-file-transfer". Adding it to the project
Failed to fetch plugin github:apache/cordova-plugin-file-transfer via registry.
Probably this is either a connection problem, or plugin spec is incorrect.
Check your connection and plugin name/version/URL.
CordovaError: Error: npm: Command failed with exit code 1 Error output:
Environment:
Where did the issue happen?
Issue occurred on a bitrise.io build using XCode 13.2.X Stack, Ionic Archive 2.X.X step
Reproducibility
- _Does a “Rebuild” help? No
- _Does a rebuild without caches help? No
- Does the issue happen sporadically, or every time? : Every Time
- Does upgrading the build Step to the latest version help? : No
- When did the issue start? : Ever since trying to add this project
Local reproduction
I do not get this error locally or when compiling using Ionic Appflow (another CI/CD option I’m looking to migrate away from)
Build log
Relevant log extract from the Ionic Archive Step:
Config:
- Platform: android
- Configuration: release
- Target: device
- BuildConfig: /var/folders/11/nh0v1jld7zd7b9zqm1774gtm0000gn/T/__bitrise-cordova-build-config__755136760/build.json
- Options: --prod --verbose
- Username:
- Password:
- RunPrepare: false
- IonicVersion:
- CordovaVersion: latest
- WorkDir: /Users/vagrant/git
- DeployDir: /Users/vagrant/deploy
- AndroidAppType: aab
- UseCache: true
Js package manager used: npm
Updating cordova version to: latest
$ npm "remove" "cordova" "--force"
$ npm "install" "-g" "cordova@latest" "--force"
cordova version: 11.0.0
ionic version: 6.19.0
Building project
$ ionic "cordova" "build" "--release" "--device" "android" "--buildConfig" "/var/folders/11/nh0v1jld7zd7b9zqm1774gtm0000gn/T/__bitrise-cordova-build-config__755136760/build.json" "--prod" "--verbose" "--" "--" "--packageType=bundle"
2022-08-30T18:58:35.028Z ionic:utils-terminal:info Environment variables for CI detected: CI
2022-08-30T18:58:35.128Z ionic:lib Terminal info: { ci: true, shell: '/bin/bash', tty: false, windows: false }
2022-08-30T18:58:35.129Z ionic:lib CLI global options: { _: [ 'cordova', 'build' ], help: null, h: null, verbose: true, quiet: null, interactive: false, color: true, confirm: null, json: null, release: true, device: 'android', buildConfig: '/var/folders/11/nh0v1jld7zd7b9zqm1774gtm0000gn/T/__bitrise-cordova-build-config__755136760/build.json', prod: true, project: null, '--': [ '--', '--packageType=bundle' ] }
2022-08-30T18:58:35.397Z ionic:lib:project Project type from config: @ionic/angular (angular)
2022-08-30T18:58:35.397Z ionic:lib:project Project details: { context: 'app', type: 'angular', errors: [], configPath: '/Users/vagrant/git/ionic.config.json' }
2022-08-30T18:58:35.400Z ionic Context: { binPath: '/usr/local/lib/node_modules/@ionic/cli/bin/ionic', libPath: '/usr/local/lib/node_modules/@ionic/cli', execPath: '/Users/vagrant/git', version: '6.19.0' }
âś” Creating ./www directory for you in 729.03ÎĽs
2022-08-30T18:58:35.456Z ionic:lib:integrations:cordova:config Loading Cordova Config (config.xml: '/Users/vagrant/git/config.xml', package.json: '/Users/vagrant/git/package.json')
> cordova platform add android --save
Using cordova-fetch for cordova-android@10.1.0
Adding android project...
Creating Cordova project for the Android platform:
Path: platforms/android
Package: com.slatedev.[REDACTED]
Name: Notis
Activity: MainActivity
Android target: android-30
Subproject Path: CordovaLib
Subproject Path: app
Android project created with cordova-android@10.1.0
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
Discovered plugin "cordova-plugin-statusbar". Adding it to the project
Installing "cordova-plugin-statusbar" for android
Adding cordova-plugin-statusbar to package.json
Discovered plugin "cordova-plugin-device". Adding it to the project
Installing "cordova-plugin-device" for android
Adding cordova-plugin-device to package.json
Discovered plugin "cordova-plugin-splashscreen". Adding it to the project
Installing "cordova-plugin-splashscreen" for android
Adding cordova-plugin-splashscreen to package.json
Discovered plugin "cordova-plugin-ionic-webview". Adding it to the project
Installing "cordova-plugin-ionic-webview" for android
Subproject Path: CordovaLib
Subproject Path: app
Adding cordova-plugin-ionic-webview to package.json
Discovered plugin "cordova-plugin-ionic-keyboard". Adding it to the project
Installing "cordova-plugin-ionic-keyboard" for android
Adding cordova-plugin-ionic-keyboard to package.json
Discovered plugin "cordova-plugin-facebook-connect". Adding it to the project
Installing "cordova-plugin-facebook-connect" for android
Subproject Path: CordovaLib
Subproject Path: app
Adding cordova-plugin-facebook-connect to package.json
Discovered plugin "cordova-plugin-camera". Adding it to the project
Installing "cordova-plugin-camera" for android
Subproject Path: CordovaLib
Subproject Path: app
Adding cordova-plugin-camera to package.json
Discovered plugin "ionic-plugin-deeplinks". Adding it to the project
Installing "ionic-plugin-deeplinks" for android
Adding ionic-plugin-deeplinks to package.json
Discovered plugin "cordova-plugin-x-socialsharing". Adding it to the project
Installing "cordova-plugin-x-socialsharing" for android
Installing "es6-promise-plugin" for android
Subproject Path: CordovaLib
Subproject Path: app
Adding cordova-plugin-x-socialsharing to package.json
Discovered plugin "cordova-plugin-geolocation". Adding it to the project
Installing "cordova-plugin-geolocation" for android
Adding cordova-plugin-geolocation to package.json
Discovered plugin "cordova-plugin-googlemaps". Adding it to the project
Installing "cordova-plugin-googlemaps" for android
Subproject Path: CordovaLib
Subproject Path: app
Official document https://github.com/mapsplugin/cordova-plugin-googlemaps-doc/blob/master/v2.6.0/README.md Please consider to buy a beer for us 🍺 https://github.com/mapsplugin/cordova-plugin-googlemaps#buy-us-a-beer
Adding cordova-plugin-googlemaps to package.json
Discovered plugin "cordova-plugin-androidx". Adding it to the project
Installing "cordova-plugin-androidx" for android
Plugin doesn't support this project's cordova-android version. cordova-android: 10.1.0, failed version requirement: <9.0.0
Skipping 'cordova-plugin-androidx' for android
Adding cordova-plugin-androidx to package.json
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /Users/vagrant/git/platforms/android/*-Info.plist, ignoring
Discovered plugin "cordova-plugin-androidx-adapter". Adding it to the project
Installing "cordova-plugin-androidx-adapter" for android
Adding cordova-plugin-androidx-adapter to package.json
Discovered plugin "cordova-plugin-filechooser". Adding it to the project
Installing "cordova-plugin-filechooser" for android
Adding cordova-plugin-filechooser to package.json
Discovered plugin "cordova-documentpicker". Adding it to the project
Installing "cordova-documentpicker" for android
Adding cordova-documentpicker to package.json
Discovered plugin "cordova-plugin-chooser". Adding it to the project
Installing "cordova-plugin-chooser" for android
Adding cordova-plugin-chooser to package.json
Discovered plugin "cordova-plugin-file-transfer". Adding it to the project
Failed to fetch plugin github:apache/cordova-plugin-file-transfer via registry.
Probably this is either a connection problem, or plugin spec is incorrect.
Check your connection and plugin name/version/URL.
CordovaError: Error: npm: Command failed with exit code 1 Error output:
npm WARN idealTree Removing dependencies.cordova-plugin-file-transfer in favor of devDependencies.cordova-plugin-file-transfer
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: @agm/core@3.0.0-beta.0
npm ERR! Found: @angular/common@12.1.5
npm ERR! node_modules/@angular/common
npm ERR! peer @angular/common@"^12.0.0 || ^13.0.0-0" from @angular/cdk@12.2.13
npm ERR! node_modules/@angular/cdk
npm ERR! peer @angular/cdk@"12.2.13" from @angular/material@12.2.13
npm ERR! node_modules/@angular/material
npm ERR! @angular/material@"^12.2.13" from the root project
npm ERR! @angular/cdk@"^12.2.13" from the root project
npm ERR! peer @angular/common@"^9.0.0 || ^10.0.0 || ^11.0.0 || ^12.0.0" from @angular/fire@6.1.5
npm ERR! node_modules/@angular/fire
npm ERR! @angular/fire@"^6.1.5" from the root project
npm ERR! 8 more (@angular/forms, @angular/material, ...)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer @angular/common@"^9.1.0 || ^10.0.0" from @agm/core@3.0.0-beta.0
npm ERR! node_modules/@agm/core
npm ERR! @agm/core@"^3.0.0-beta.0" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: @angular/common@10.2.5
npm ERR! node_modules/@angular/common
npm ERR! peer @angular/common@"^9.1.0 || ^10.0.0" from @agm/core@3.0.0-beta.0
npm ERR! node_modules/@agm/core
npm ERR! @agm/core@"^3.0.0-beta.0" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See /Users/vagrant/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/vagrant/.npm/_logs/2022-08-30T18_58_42_962Z-debug-0.log
[ERROR] An error occurred while running subprocess cordova.
cordova platform add android --save exited with exit code 1.
Re-running this command with the --verbose flag may provide more information.
2022-08-30T18:58:47.504Z ionic:utils-process onBeforeExit handler: 'process.exit' received
2022-08-30T18:58:47.504Z ionic:utils-process onBeforeExit handler: running 1 functions
2022-08-30T18:58:47.540Z ionic:utils-process processExit: exiting (exit code: 1)
command failed, error: exit status 1