twilio/twilio-cli

URGENT: oclif/core dependency broken in all Twilio CLI Versions

Closed this issue · 4 comments

Issue Summary

All Twilio Flex CLI Commands Fail with "TypeError: Cannot read properties of undefined (reading 'warnIfFlagDeprecated')"

This has been discussed with here oclif/core#528 oclif/core dependency.

This has broke all versions of the Twilio CLI.

Steps to Reproduce

  1. npm install -g twilio-cli && twilio plugins:install @twilio-labs/plugin-flex
  2. twilio flex:plugins:build

Exception/Log

/home/runner/.twilio-cli/node_modules/@oclif/core/lib/command.js:153
        this.warnIfFlagDeprecated(results.flags ?? {});
             ^

TypeError: Cannot read properties of undefined (reading 'warnIfFlagDeprecated')
    at parse (/home/runner/.twilio-cli/node_modules/@oclif/core/lib/command.js:153:14)
    at async /home/runner/.twilio-cli/node_modules/@twilio-labs/plugin-flex/dist/utils/parser.js:113:42
    at async FlexPluginsBuild.init (/home/runner/.twilio-cli/node_modules/@twilio-labs/plugin-flex/dist/sub-commands/flex-plugin.js:254:24)
    at async FlexPluginsBuild._run (/home/runner/.twilio-cli/node_modules/@oclif/core/lib/command.js:79:13)
    at async Config.runCommand (/opt/hostedtoolcache/node/[16](https://github.com/Ciptex/plugin-race-core/actions/runs/3274361825/jobs/5387782716#step:10:17).[17](https://github.com/Ciptex/plugin-race-core/actions/runs/3274361825/jobs/5387782716#step:10:18).1/x64/lib/node_modules/twilio-cli/node_modules/@oclif/core/lib/config/config.js:272:25)
    at async Object.run (/opt/hostedtoolcache/node/16.17.1/x64/lib/node_modules/twilio-cli/node_modules/@oclif/core/lib/main.js:76:5)
Error: Process completed with exit code 1.

Technical details:

  • twilio-cli version: 5.1.0
  • node version: 16

Hi @moretalk , thanks for reaching out! As you've linked the oclif issue, it's being addressed internally be flex team.

@twilio/flex-developers @aishwarya-tw

Hi @moretalk , flex has released a patch with the required fix, v6.0.2, please use that, it should solve the problem.

Resolved in flex v6.0.2.