bobobobo opened a new issue, #962: URL: https://github.com/apache/cordova-lib/issues/962
# Bug Report ## Problem Installing a plugin from a private repository using an npm alias causes cordova to fail to restore plugin. ### What is expected to happen? Plugin restored correctly from private repository when running `cordova prepare` ### What does actually happen? When running `cordova prepare` the plugin restore fails with the following error: ``` Failed to restore plugin "cordova-plugin-geolocation". You might need to try adding it again. Error: CordovaError: Failed to fetch plugin npm:@MyOrg/cordova-plugin-geolocation@4.1.0 via registry. Probably this is either a connection problem, or plugin spec is incorrect. Check your connection and plugin name/version/URL. CordovaError: HttpErrorGeneral: 404 Not Found - GET https://registry.npmjs.org/@MyOrg%2fcordova-plugin-geolocation - Not found ``` ## Information <!-- Include all relevant information that might help understand and reproduce the problem --> Modified plugin deployed to Github Packages in Organization @MyOrg and added as alias to `package.json` using the following format: `"cordova-plugin-geolocation": "npm:@MyOrg/cordova-plugin-geolocation@4.1.0"` Running `npm install` works fine. The plugin is downloaded from Github Packages and added to `node_modules` correctly under the name `cordova-plugin-geolocation`. But when running `cordova prepare`, the plugin is not restored correctly, and fails with the error above. Npm is logged in using the following command to make @MyOrg dependencies to be installed from Github Packages. `npm login --registry=https://npm.pkg.github.com --scope=@MyOrg` ### Version information - Cordova CLI 12.0.0 ## Checklist <!-- Please check the boxes by putting an x in the [ ] like so: [x] --> - [x] I searched for existing GitHub issues - [x] I updated all Cordova tooling to most recent version - [x] I included all the necessary information above -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org