-
Notifications
You must be signed in to change notification settings - Fork 36
04. Troubleshooting
To work with our developer-version or to install a specific older version you can select any branch or tag from our git repository during install to do so:
Most recent developer version (using the GitHub repo & branch name):
npm install -g accenture/sfmc-devtools#develop
Note: Regardless of which tag or branch you install
Install specific version (using a version tag on npm):
npm install -g mcdev@4.2.0
Warning: When you used the above method to install Accenture SFMC DevTools for a specific version or tag, trying to update Accenture SFMC DevTools might not download the most recently published official version but instead stay on the version or branch you previously selected (in the above examples: develop, 4.2.0)!
Note: The version is currently not updated on the developer branch until a new release is published. Hence, you will not see a change if you run
mcdev --version
.
Some users of Accenture SFMC DevTools prefer to use git bash or other CLIs instead of the operating system's default. Please note that some of the functionality of Accenture SFMC DevTools but also other tools like the Node package manager (npm) do not necessarily function properly in these.
If you encounter problems, we strongly recommend first trying it in the default CLI.
Depending on your setup, the default global installs & updates might error out with "Missing write access to /usr/local/lib/node_modules". In this case, prefix your command with sudo
:
sudo npm install -g mcdev
sudo npm update -g mcdev
If you see the below error then your system's security settings are rather strict.
Steps to solve this:
- Start Windows PowerShell with the "Run as Administrator" option.
- Input the following and then hit ENTER:
set-executionpolicy remotesigned
- Either you are done now - or you will be prompted with a question to confirm the change (screenshot below). Please type
y
(="yes") and confirm withEnter
.
Please note that this change is global and not just for your current folder.
If you encounter out of the 3 following errors you will have to completely remove Node.JS and install it again afterwards.
Error 1: Cannot find module index.js
Error 2: Operation not permitted
How to completely remove Node.js from Windows:
-
Run npm cache clean --force
-
Uninstall it via the system's
Add or remove programs
(find it by searching in the start menu). -
Reboot your computer.
-
Look for these folders and remove them (and their contents) if any still exist. Depending on the version you installed, UAC settings, and CPU architecture, these may or may not exist:
- C:\Program Files (x86)\Nodejs
- C:\Program Files\Nodejs
- C:\Users\{User}\AppData\Roaming\npm
- (or %appdata%\npm)
- C:\Users\{User}\AppData\Roaming\npm-cache
- (or %appdata%\npm-cache)
- C:\Users\{User}.npmrc (and possibly check for that without the . prefix too)
- C:\Users\{User}\npmrc
- C:\Users\{User}\AppData\Local\Temp\npm-*
-
Check your %PATH% environment variable to ensure no references to Nodejs or npm exist.
-
If it's still not uninstalled, type
where node
at the command prompt and you'll see where it resides -- delete that (and probably the parent directory) too. -
Reboot again!
Re-install Node.js and Accenture SFMC DevTools:
Now, please follow the guides above in the Pre-requisites section to Install Node.js again and afterwards try again to install Accenture SFMC DevTools.
Copyright (c) 2020-2024 Accenture. MIT licensed. Main contributors: Jörn Berkefeld, Doug Midgley