ember-cli-update
ember-cli-update copied to clipboard
Can't ran any of the codemods
Updating app to the latest Ember version (3.24.0) succeeded but running any of the codemods after that always fail:
Output from command with debug flag:
$ DEBUG=ember-cli-update,boilerplate-update,git-diff-apply ember update --run-codemods
Browserslist: caniuse-lite is outdated. Please run:
npx browserslist@latest --update-db
Running as an Ember addon is deprecated. Please run as a global install instead.
? Which blueprint would you like to run codemods for? ember-cli
? These codemods apply to your project. Select which ones to run. es5-getter-ember-codemod
Running codemod es5-getter-ember-codemod
Running command 1 of 1
boilerplate-update npx github:rondale-sc/es5-getter-ember-codemod es5-getter-ember-codemod app/**/*.js tests/*.js tests/!(dummy)/**/*.js tests/dummy/app/**/*.js +0ms
boilerplate-update npx github:rondale-sc/es5-getter-ember-codemod es5-getter-ember-codemod app/**/*.js tests/*.js tests/!(dummy)/**/*.js tests/dummy/app/**/*.js {
preferLocal: true,
stdio: [ 'pipe', 'pipe', 'inherit' ],
cwd: '/home/lucas/Workspace/src/github.com/lowski/fapiao'
} +1ms
npm ERR! cb.apply is not a function
npm ERR! A complete log of this run can be found in:
npm ERR! /home/lucas/.npm/_logs/2021-01-24T14_12_32_031Z-debug.log
Install for [ 'github:rondale-sc/es5-getter-ember-codemod' ] failed with code 1
Error running command github:rondale-sc/es5-getter-ember-codemod es5-getter-ember-codemod app/**/*.js tests/*.js tests/!(dummy)/**/*.js tests/dummy/app/**/*.js
Error: Command failed with exit code 1: npx github:rondale-sc/es5-getter-ember-codemod es5-getter-ember-codemod app/**/*.js tests/*.js tests/!(dummy)/**/*.js tests/dummy/app/**/*.js
at makeError (/home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/boilerplate-update/node_modules/execa/lib/error.js:59:11)
at handlePromise (/home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/boilerplate-update/node_modules/execa/index.js:114:26)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
at async Object.runCodemod (/home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/boilerplate-update/src/run-codemod.js:21:9)
at async runCodemods (/home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/boilerplate-update/src/run-codemods.js:7:5)
at async promptAndRunCodemods (/home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/boilerplate-update/src/prompt-and-run-codemods.js:20:3)
at async codemods (/home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/ember-cli-update/src/codemods.js:80:10)
at async Class.run (/home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/ember-cli-update/src/command.js:99:16)
at async /home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/ember-cli/lib/cli/cli.js:204:32
at async CLI.run (/home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/ember-cli/lib/cli/cli.js:251:14)
at async module.exports (/home/lucas/Workspace/src/github.com/lowski/fapiao/node_modules/ember-cli/lib/cli/index.js:145:12)
boilerplate-update git add -A { cwd: '/home/lucas/Workspace/src/github.com/lowski/fapiao' } +1s
Cannot read property 'resolveConflictsProcess' of undefined
Stack Trace and Error Report: /tmp/error.dump.a7f40e3ebdb5556e6ac210592d1140eb.log
After quick research it looks like it might be an issue with https://github.com/isaacs/node-graceful-fs/issues/192 but I'm not sure how to fix it.
Also just upgraded. Same issue.
Same issue here
Update:
I went back and tried the upgrade again and had some success. This was an add-on upgrade from 3.12 -> 3.16. I'm not sure my steps fixed the issue but I wanted to document them
- I realized that I'm running Node 14 and Ember 3.12 is Node 8/10, so I rolled back to Node 12 (not sure this did anything)
- I ran the codemods before the upgrade to make sure there weren't problems before upgrading - all codemods selected, no issues
- Ran the upgrade - no issues
- Ran the codemods post upgrade - had some failures
- ember-modules-codemod
- ember-qunit-codemod
- ember-test-helpers-codemod
- es5-getter-ember-codemod
These codemods failed with the error: Cannot read property 'resolveConflictsProcess' of undefined
. These would not run at all previously. These errors may be related to devDeps that weren't updated in the process or that this is an addon not an app.
I'll work on this some more and update again
3/10/21 Update to the update
From my last update, I didn't realize that I upgraded all the way to 3.25, not 3.16. When I reversed the update and then updated to 3.16 I could run the codemods without errors.
I still needed to be on Node 12.
I'm seeing this same issue, I believe, when using node 12.x. When I revert to node 10.x it appears to be resolved.
@ballPointPenguin are you using yarn or npm?
I’m using yarn and was seeing errors related to node-gyp errors related to node 14. Rolling back to 12 fixed those errors and I could use ember-cli-update. I’m planning to test against npm
@maxwondercorn I'm using npm 6. node 12 + npm 6 ☹️ node 10 + npm 6 😁
Same issue, any updates on this issue? node 12 npm 6 ember-cli: 3.28.4
Wondering if anyone has a fix for this? I have a smaller app I would like to update but cannot run codemods on it because of this issue.
Look at this commit for node 12 and 14 versions which work https://github.com/ember-cli/ember-cli-update/commit/355af989100ef9040bc7be0a5310a6e6de198ca4
The file in question mentions version greater than 14.5 have a regression and will not work.
I had the same issue with cb.appply
on 14.18/ 16.13, but downgrading to 14.4 allowed me to run the codemods.
https://github.com/ember-cli/ember-cli-update/blob/07ca9a25650ef2f02950d7a39a26859cfb6e7c4b/appveyor.yml#L3-L6
This should be mentioned in the README or somewhere like that....