When deploying the source code for version 2019.1, we initially need to update the deployment process to use token-based authentication. However, after making this change, we encountered errors in the terminal that prevent successful deployment.
The error messages include:
getFileNamedsearcherror undefinedThe following tasks did not complete: deploy, deployDid you forget to signal async completion?
Solution
- First, download the latest files from the backup folder in the SSP.
- Extract the files into a new folder and run the following command:
npm install
- For version 2019.1, ensure you are using Node.js version 10.24.1 for compatibility.
- Update the deployment process to use token-based authentication.
- Refer to the SuiteAnswer article with ID: 97830 for detailed instructions.
- After applying all patches as outlined in the article, run the following commands:
gulp local
gulp deploy
- During this process, you may encounter the following errors:
getFileNamedsearcherror undefined
The following tasks did not complete: deploy, deploy
Did you forget to signal async completion?
- Possible Cause of the Issue:
- One potential cause is the presence of Zero-Width Non-Joiner (U+200C) space characters in the code.
- These characters are invisible and may cause unexpected behavior.
Example
Line of code in the SuitAnswer : <nsmessages:account>{{credentials.account}}</nsmessages:account>
When we paste the same line of code in Notepad++ . its like below
<nsmessages:account>{{zwnjcredentials.account}}</nsmessages:account>
Steps to Resolve:
- Download and install Notepad++.
- Paste the code into Notepad++ and follow these steps
Go to View > Show Symbol > Show Non-Printing Characters or Show All Characters.
Identify and remove any zero-width non-joiner characters.
After removing the characters, ensure that the cleaned-up patches are added back to the appropriate files.
Save the updated files and attempt to re-deploy the code.