1

I am facing following error when building a project that builds Swagger UI. It was working fine and suddenly the issue came up. In the pom file, I have this:

<groupId>com.github.eirslett</groupId>
<artifactId>frontend-maven-plugin</artifactId>
<version>1.10.0</version>

Any idea about what might be the issue?

[INFO] ERROR in ./~/swagger-ui/dist/swagger-ui-es-bundle.js
[INFO] Module parse failed: ....\node_modules\swagger-ui\dist\swagger-ui-es-bundle.js 
Unexpected token (2:240243)
[INFO] You may need an appropriate loader to handle this file type.
[INFO] (Source code omitted for this binary file)
[INFO]  @ ./example.js 17:17-38
[INFO]  @ ./example1.js
[INFO]  @ multi ./example.js
[INFO] npm ERR! code ELIFECYCLE
[INFO] npm ERR! errno 2
[INFO] npm ERR! proj@1.0.0 build: `webpack`
[INFO] npm ERR! Exit status 2
[INFO] npm ERR!
[INFO] npm ERR! Failed at the proj@1.0.0 build script.
[INFO] npm ERR! This is probably not a problem with npm. There is likely additional 
logging output above.
[INFO]
[INFO] npm ERR! A complete log of this run can be found in:
[INFO] npm ERR!     ..\npm-cache\_logs\2021-08-24T12_07_22_641Z-debug.log
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.github.eirslett:frontend-maven-plugin:1.10.0:npm 
(prod) on project proj: Failed to run task: 'npm run-script build' failed. 
org.apache.commons.exec.ExecuteException: Process exited with an error: 2 (Exit value: 
2) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the 
following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :proj
acm
  • 77
  • 3
  • 11

0 Answers0