Expand my Community achievements bar.

AEM WKND Tutorial Installation Error

Avatar

Level 1

Hello,

I'm following the WKND site tutorial for Intellij (https://experienceleague.adobe.com/docs/experience-manager-learn/foundation/development/set-up-a-loc...) and am having a similar problem as this fellow had: https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/npm-error-running-pautoins...

 

Following the above answer's advice, I made sure to download and use the latest stable node version via nvm. I'm on a Windows machine with node version 16.17.0

 

In Intellij's maven window, using the profile "autoInstallPackage" and attempting to run the "install" lifecycle, I get the following. Please advise, thanks!

 

Additionally, in the Intellij video, the author navigates to https://repo.adobe.com to attain an XML settings file which he later adds to his maven settings, but when navigate to that address, I get a 404.



[INFO] ERROR in C:\Users\Work\Desktop\adobe\aem-guides-wknd\ui.frontend\node_modules\@types\express-serve-static-core\index.d.ts
[INFO] 1255:0
[INFO] [tsl] ERROR in C:\Users\Work\Desktop\adobe\aem-guides-wknd\ui.frontend\node_modules\@types\express-serve-static-core\index.d.ts(1255,1)
[INFO] TS1160: Unterminated template literal.
[INFO] ts-loader-default_e3b0c44298fc1c14
[INFO]
[INFO] 2022-09-20 16:07:34: webpack 5.74.0 compiled with 127 errors and 2 warnings in 12028 ms
[INFO] npm ERR! code ELIFECYCLE
[INFO] npm ERR! errno 1
[INFO] npm ERR! aem-maven-archetype@1.0.0 prod: `webpack --config ./webpack.prod.js && clientlib --verbose`
[INFO] npm ERR! Exit status 1
[INFO] npm ERR!
[INFO] npm ERR! Failed at the aem-maven-archetype@1.0.0 prod 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! C:\Users\Work\AppData\Roaming\npm-cache\_logs\2022-09-20T21_07_34_461Z-debug.log
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for WKND Sites Project 0.0.1-SNAPSHOT:
[INFO]
[INFO] WKND Sites Project ................................. SUCCESS [ 0.173 s]
[INFO] WKND Sites Project - Core .......................... SUCCESS [ 3.544 s]
[INFO] WKND Sites Project - UI Frontend ................... FAILURE [ 23.220 s]
[INFO] WKND Sites Project - Repository Structure Package .. SKIPPED
[INFO] WKND Sites Project - UI apps ....................... SKIPPED
[INFO] WKND Sites Project - UI content .................... SKIPPED
[INFO] WKND Sites Project - UI config ..................... SKIPPED
[INFO] WKND Sites Project - All ........................... SKIPPED
[INFO] WKND Sites Project - Integration Tests ............. SKIPPED
[INFO] WKND Sites Project - Dispatcher .................... SKIPPED
[INFO] WKND Sites Project - UI Tests ...................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 28.243 s
[INFO] Finished at: 2022-09-20T16:07:34-05:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.github.eirslett:frontend-maven-plugin:1.12.0:npm (npm run prod) on project aem-guides-wknd.ui.frontend: Failed to run task: 'npm run prod' failed. org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1) -> [Help 1]

7 Replies

Avatar

Employee

Can you check and tell which version of the npm used in pom.xml of UI Frontend?

 

Thanks,

Vijendra

Avatar

Employee

For the Node version you have installed 16.17.0 the compatible npm version should be 8.15.0.

 

Either you downgrade the node version matching to your existing npm or change the npm as mentioned above.

 

Thanks,

Vijendra

Avatar

Level 1

Thanks,

 

The pom of ui.frontend did not specify an node or npm version, but the root pom does have a specification for the frontend-maven-plugin to use node v12.22.7 and npm v 6.14.

 

However, when I downgrade my node and npm to these versions, I'm getting the same error as above.

Avatar

Level 3

This is caused because of the outdated 'typescript' version in the package.json file of ui.frontend module.

 

Updating the typescript version to - ^4.8.2 in "devDependencies" section of package.json file in ui.frontend module resolves the issue. Please test and confirm back!

 

"typescript": "^4.8.2",

Avatar

Level 1

Thank you,

 

I have the same error shown. I am able to deploy after changing the version for type script to 4.8.2 

Avatar

Employee

This solution really worked for me. Thank you, I was stuck for few hours in this by changing node and npm versions.