Issue Description
When an API project uses a deprecated reactioncommerce plugin, the reaction update command fails. When the CLI checks for version mismatch between the local plugin version and the latest remote plugin versions it compares the version of all local plugins to the remote ones. The problem arises when a project uses a deprecated plugin that's not present in the latest reactioncommerce API. Example of the that is the @reactioncommerce/api-plugin-payments-stripe.
If a the local project uses the @reactioncommerce/api-plugin-payments-stripe, when we check for the version of the plugin on the remote project here:
|
outdated: compareVersions.compare(cleanVersion(remoteDependencies[name]), cleanVersion(version), ">") |
We get the following error:
Error: Invalid argument not valid semver ('' received)
This happens because the version of @reactioncommerce/api-plugin-payments-stripe on the remote project resolves to an empty string.
Instead of failing, the update command should display a warning message that the local project depends on a deprecated official plugin.
Steps to Reproduce
- Create a local project that uses the
@reactioncommerce/api-plugin-payments-stripe plugin
- Run the
reaction update command for this project
- The command fails with the error message mentioned previously in the issue
Issue Description
When an API project uses a deprecated reactioncommerce plugin, the
reaction updatecommand fails. When the CLI checks for version mismatch between the local plugin version and the latest remote plugin versions it compares the version of all local plugins to the remote ones. The problem arises when a project uses a deprecated plugin that's not present in the latest reactioncommerce API. Example of the that is the@reactioncommerce/api-plugin-payments-stripe.If a the local project uses the
@reactioncommerce/api-plugin-payments-stripe, when we check for the version of the plugin on the remote project here:cli/commands/update.js
Line 118 in 7ab5268
We get the following error:
This happens because the version of
@reactioncommerce/api-plugin-payments-stripeon the remote project resolves to an empty string.Instead of failing, the
updatecommand should display a warning message that the local project depends on a deprecated official plugin.Steps to Reproduce
@reactioncommerce/api-plugin-payments-stripepluginreaction updatecommand for this project