Unrecognized CLI options with Serverless 3
See original GitHub issueThis is a bug report
Expected behavior
Passing CLI options for this plugin (e.g. --no-confirm
) should work with Serverless 3.
Actual behavior
Deploy fails with the error:
Detected unrecognized CLI options: "--confirm".
Steps to reproduce
- Operating system: Windows 11
- serverless-finch version: 2.6.0
serverless.yml
that produces bug: any- Command that produces bug:
serverless deploy --no-confirm
- Other details:
I believe this is because Serverless 3 throws an error for any unrecognized options, and this plugin doesn’t define the options as documented in the Serverless plugins guide.
I tested defining the option like this and it seemed to resolve the issue:
this.commands = {
client: {
usage: 'Generate and deploy clients',
lifecycleEvents: ['client', 'deploy'],
commands: {
deploy: {
usage: 'Deploy serverless client code',
lifecycleEvents: ['deploy'],
options: {
confirm: {
usage: 'Display a confirmation prompt',
type: 'boolean'
}
}
},
I can create a pull request but I’m not aware of all the possible command options, and I’m also not sure whether you’d prefer to move the command definitions to a new file, since it will probably get quite a bit longer if every option is defined here.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:4
- Comments:5 (1 by maintainers)
Top Results From Across the Web
opt:some_var Detected unrecognized CLI options · Issue #9371
Hello @Wurstnase - support for custom CLI options is going to be deprecated in 3.0.0 and we recommend using e.g. environment variables in ......
Read more >Serverless Framework Deprecations
Handling of unrecognized CLI options. Deprecation code: UNSUPPORTED_CLI_OPTIONS. CLI options validation was introduced to detect typos and mistakes.
Read more >Detected unrecognized CLI options: "--profile" - Stack Overflow
I am trying to deploy my code to AWS using Serverless through Gitlab cicd. All stages have been passed but when ...
Read more >detected unrecognized cli options serverless - You.com
I believe this is because Serverless 3 throws an error for any unrecognized options, and this plugin doesn't define the options as documented...
Read more >serverless-offline/community - Gitter
Hey peep, any one having issues with serverless offline that it just hangs at ... I'm getting hit with Detected unrecognized CLI options:...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’ve created a pull request, but for anyone who would like to use this plugin with Serverless 3 in the meantime, I’ve published my fork to NPM at
@boundstate/serverless-finch
.@mikejpeters appreciate the fix! Would you be interested in helping with #142 and merging your fix in here? Unfortunately I am no longer able to maintain this plugin and am looking to find folks who can help maintain the plugin long term.