Skip to content
This repository has been archived by the owner on Apr 17, 2023. It is now read-only.

BugFix: CLIEngine is not constructor when format called #1271

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

pbardov
Copy link

@pbardov pbardov commented May 1, 2022

Bug fix. When installed latest prettier-eslint and eslint, prettier-atom format ends with following error:
/home/pavel/.atom/packages/prettier-atom/dist/executePrettier/handleError.js:50 TypeError: CLIEngine is not a constructor at getESLintCLIEngine (/home/pavel/.atom/packages/prettier-atom/node_modules/@lewisl9029/prettier-eslint/dist/utils.js:403) at getESLintConfig (/home/pavel/.atom/packages/prettier-atom/node_modules/@lewisl9029/prettier-eslint/dist/index.js:212) at format (/home/pavel/.atom/packages/prettier-atom/node_modules/@lewisl9029/prettier-eslint/dist/index.js:75) at /home/pavel/.atom/packages/prettier-atom/dist/executePrettier/executePrettierOnBufferRange.js:64 at exports.allowUnsafeNewFunction (/home/pavel/.atom/packages/prettier-atom/node_modules/loophole/lib/loophole.js:25) at executePrettierEslint (/home/pavel/.atom/packages/prettier-atom/dist/executePrettier/executePrettierOnBufferRange.js:64) at /home/pavel/.atom/packages/prettier-atom/dist/executePrettier/executePrettierOnBufferRange.js:86 at Generator.next (<anonymous>) at asyncGeneratorStep (/home/pavel/.atom/packages/prettier-atom/node_modules/@babel/runtime/helpers/asyncToGenerator.js:3) at _next (/home/pavel/.atom/packages/prettier-atom/node_modules/@babel/runtime/helpers/asyncToGenerator.js:25) at /home/pavel/.atom/packages/prettier-atom/node_modules/@babel/runtime/helpers/asyncToGenerator.js:32 at new Promise (<anonymous>) at /home/pavel/.atom/packages/prettier-atom/node_modules/@babel/runtime/helpers/asyncToGenerator.js:21 at executePrettierOrIntegration (/home/pavel/.atom/packages/prettier-atom/dist/executePrettier/executePrettierOnBufferRange.js:108) at /home/pavel/.atom/packages/prettier-atom/dist/executePrettier/executePrettierOnBufferRange.js:126 at Generator.next (<anonymous>) at asyncGeneratorStep (/home/pavel/.atom/packages/prettier-atom/node_modules/@babel/runtime/helpers/asyncToGenerator.js:3) at _next (/home/pavel/.atom/packages/prettier-atom/node_modules/@babel/runtime/helpers/asyncToGenerator.js:25) at /home/pavel/.atom/packages/prettier-atom/node_modules/@babel/runtime/helpers/asyncToGenerator.js:32 at new Promise (<anonymous>) at /home/pavel/.atom/packages/prettier-atom/node_modules/@babel/runtime/helpers/asyncToGenerator.js:21 at executePrettierOnBufferRange (/home/pavel/.atom/packages/prettier-atom/dist/executePrettier/executePrettierOnBufferRange.js:156) at executePrettierOnCurrentBufferRange (/home/pavel/.atom/packages/prettier-atom/dist/manualFormat/index.js:25) at n (/home/pavel/.atom/packages/prettier-atom/node_modules/lodash/lodash.min.js:9) at /home/pavel/.atom/packages/prettier-atom/node_modules/lodash/lodash.min.js:107 at n (/home/pavel/.atom/packages/prettier-atom/node_modules/lodash/lodash.min.js:9) at /home/pavel/.atom/packages/prettier-atom/node_modules/lodash/lodash.min.js:73 at /home/pavel/.atom/packages/prettier-atom/node_modules/lodash/lodash.min.js:57 at n (/home/pavel/.atom/packages/prettier-atom/node_modules/lodash/lodash.min.js:9) at /home/pavel/.atom/packages/prettier-atom/node_modules/lodash/lodash.min.js:107 at n (/home/pavel/.atom/packages/prettier-atom/node_modules/lodash/lodash.min.js:9) at /home/pavel/.atom/packages/prettier-atom/node_modules/lodash/lodash.min.js:73 at HTMLElement.<anonymous> (/home/pavel/.atom/packages/prettier-atom/dist/main.js:72) at CommandRegistry.handleCommandEvent (/usr/share/atom/resources/app/static/<embedded>:11) at KeymapManager.dispatchCommandEvent (/usr/share/atom/resources/app/static/<embedded>:11) at KeymapManager.handleKeyboardEvent (/usr/share/atom/resources/app/static/<embedded>:11)

@pbardov pbardov closed this May 1, 2022
@pbardov pbardov reopened this May 1, 2022
@shellscape
Copy link

@robwise can we get this one merged?

(tagging @idahogurl here for visibility)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants