You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running a command that uses prompt, such as bit remove on node version v14.2.0 or above, it throws a warning.
Steps to Reproduce
use node >= v14.2.0
bit remove your-component
You'll get the following error:
➜ nm node --trace-warnings ~/teambit/bit/bin/bit.js remove bit.tmp1/foo-bar
are you sure you would like to proceed with this operation? (yes[y]/no[n])': (node:3829) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
at emitCircularRequireWarning (internal/modules/cjs/loader.js:823:11)
at Object.get (internal/modules/cjs/loader.js:837:5)
at Object.exports.setLevels (/Users/davidfirst/teambit/bit/node_modules/prompt/node_modules/winston/lib/winston/common.js:35:14)
at Object.<anonymous> (/Users/davidfirst/teambit/bit/node_modules/prompt/node_modules/winston/lib/winston.js:84:8)
at Module._compile (internal/modules/cjs/loader.js:1200:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1220:10)
at Module.load (internal/modules/cjs/loader.js:1049:32)
at Function.Module._load (internal/modules/cjs/loader.js:937:14)
at Module.require (internal/modules/cjs/loader.js:1089:19)
at require (internal/modules/cjs/helpers.js:73:18)
at Object.<anonymous> (/Users/davidfirst/teambit/bit/node_modules/prompt/lib/prompt.js:14:15)
at Module._compile (internal/modules/cjs/loader.js:1200:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1220:10)
at Module.load (internal/modules/cjs/loader.js:1049:32)
at Function.Module._load (internal/modules/cjs/loader.js:937:14)
at Module.require (internal/modules/cjs/loader.js:1089:19)
Expected Behavior
should show a prompt message asking you to enter yes/no.
Specifications
Bit version: 14.8.8
Node version: 14.2.0
npm / yarn version:
Platform:
Bit compiler (include version):
Bit tester (include version):
Additional context
This is happening due to the prompt package that requires an old version of Winston. See flatiron/prompt#199 for more info.
Sadly, this package is not maintained. An alternative could be https://www.npmjs.com/package/enquirer or forking prompt and upgrading its Winston version.
The text was updated successfully, but these errors were encountered:
I'm new to bit and I found this really confusing as it occurred when I tried to export for the first time. It just looked like the export process had stalled.
Seems to be fixed now. The prompt package has released a new version 1.1.0 two months ago. I tried the bit remove command with node v14.5.0 and didn't get the warning.
Describe the bug
When running a command that uses prompt, such as
bit remove
on node version v14.2.0 or above, it throws a warning.Steps to Reproduce
bit remove your-component
You'll get the following error:
Expected Behavior
should show a prompt message asking you to enter yes/no.
Specifications
Additional context
This is happening due to the
prompt
package that requires an old version of Winston. See flatiron/prompt#199 for more info.Sadly, this package is not maintained. An alternative could be https://www.npmjs.com/package/enquirer or forking prompt and upgrading its Winston version.
The text was updated successfully, but these errors were encountered: