bower not found, but it is present

\u0000When I try to migrate to Vaadin 14 the migration tool keeps failing on a missing bower, but it is really there as the first line shows\n\n\nC:\\Users\\user\\Documents\\tesla\\teslaWebapp>C:\\Users\\user\\AppData\\Roaming\\npm\\bower.cmd -v\n1.8.8\n\nC:\\Users\\user\\Documents\\tesla\\teslaWebapp>mvn vaadin:migrate-to-p3\n[INFO] Scanning for projects...\n[INFO] \n[INFO] -------------------< nl.softworks.tesla:teslaWebapp >-------------------\n[INFO] Building TeslaWebapp 20191001.1343\n[INFO] --------------------------------[ war ] ---------------------------------\n[INFO] \n[INFO] --- vaadin-maven-plugin:14.0.7:migrate-to-p3 (default-cli) @ teslaWebapp ---\n[ERROR] Command '[C:\\Users\\user\\AppData\\Roaming\\npm\\bower.cmd, -v] ' failed with exit code '9009'\nnpm WARN deprecated bower@1.8.8: We don't recommend using Bower for new projects. Please consider Yarn and Webpack or Parcel. You can read how to migrate legacy project here: https://bower.io/blog/2017/how-to-migrate-away-from-bower/\nnpm WARN deprecated babel-preset-es2015@6.24.1: \uD83D\uDE4C Thanks for using Babel: we recommend using babel-preset-env now: please read https://babeljs.io/env to update!\nnpm WARN deprecated nomnom@1.8.1: Package no longer supported. Contact support@npmjs.com for more info.\nnpm WARN no-name@ No repository field.\n\n+ polymer-modulizer@0.4.3\n+ bower@1.8.8\nupdated 2 packages and audited 3006 packages in 26.12s\nfound 1 low severity vulnerability\n run `npm audit fix` to fix them, or `npm audit` for details\n[ERROR] Command '[C:\\Users\\user\\AppData\\Roaming\\npm\\bower.cmd, -v] ' failed with exit code '9009'\n[INFO] ------------------------------------------------------------------------\n[INFO] BUILD FAILURE\n[INFO] ------------------------------------------------------------------------\n[INFO] Total time: 35.412 s\n[INFO] Finished at: 2019-10-11T17:18:49+02:00\n[INFO] ------------------------------------------------------------------------\n[ERROR] Failed to execute goal com.vaadin:vaadin-maven-plugin:14.0.7:migrate-to-p3 (default-cli) on project teslaWebapp: Could not locate bower. Install it manually on your system and re-run migration goal. -> [Help 1] \n[ERROR] \n[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.\n[ERROR] Re-run Maven using the -X switch to enable full debug logging.\n[ERROR] \n[ERROR] For more information about the errors and possible solutions, please read the following articles:\n[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException\n\n

This seems to be a Windows issue. If I install the linux subsystem with Ubuntu and run the command from there, it gets past this point. Now I get a “Maximum call stack size exceeded”, but that is another problem.

Getting the migration tool to run on Windows is not a success. Having circumvented a number of issues, right now I’m stuck at “Could not install bower components”.

I’m suspecting compatibility mode will only be a short term solution.

By combining the linux subsystem and installing bower there, I was able to run the plugin eventually.