# Module not allowed for JSONata

**URL:** <https://discourse.nodered.org/t/module-not-allowed-for-jsonata/78252>\
**Category:** General\
**Tags:** function-node\
**Created:** [7 May 2023 19:57 UTC](https://discourse.nodered.org/t/module-not-allowed-for-jsonata/78252 "2023-05-07T19:57:54Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![danielterra](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/danielterra/32/75090_2.png) [@danielterra](https://discourse.nodered.org/u/danielterra)\
**Post date:** [7 May 2023 19:57 UTC](https://discourse.nodered.org/t/module-not-allowed-for-jsonata/78252/1 "2023-05-07T19:57:54Z")

</div>

Hi there, im using the external modules of the function node to work some magic with Jsonata, all works well for sometime, but when the server need to be re-started it trows some errors trying to install jsonata;

Im hosting NR on Elastic-Beanstalk

```auto
May 7 19:03:34 ip-172-31-81-152 web: > nova-node-red@1.1.0 start
May 7 19:03:34 ip-172-31-81-152 web: > ./node_modules/.bin/node-red -s ./settings.js
May 7 19:03:36 ip-172-31-81-152 web: prepop flows
May 7 19:03:36 ip-172-31-81-152 web: 7 May 19:03:36 - [info]
May 7 19:03:36 ip-172-31-81-152 web: Welcome to Node-RED
May 7 19:03:36 ip-172-31-81-152 web: ===================
May 7 19:03:36 ip-172-31-81-152 web: 7 May 19:03:36 - [info] Node-RED version: v3.0.2
May 7 19:03:36 ip-172-31-81-152 web: 7 May 19:03:36 - [info] Node.js version: v16.16.0
May 7 19:03:36 ip-172-31-81-152 web: 7 May 19:03:36 - [info] Linux 4.14.287-215.504.amzn2.x86_64 x64 LE
May 7 19:03:37 ip-172-31-81-152 web: 7 May 19:03:37 - [info] Loading palette nodes
May 7 19:03:38 ip-172-31-81-152 web: 7 May 19:03:38 - [info] Settings file : /var/app/current/settings.js
May 7 19:03:38 ip-172-31-81-152 web: 7 May 19:03:38 - [info] Context store : 'default' [module=memory]
May 7 19:03:39 ip-172-31-81-152 web: 7 May 19:03:39 - [info] Server now running at http://127.0.0.1:8080/
May 7 19:03:40 ip-172-31-81-152 web: 7 May 19:03:40 - [warn]
May 7 19:03:40 ip-172-31-81-152 web: ---------------------------------------------------------------------
May 7 19:03:40 ip-172-31-81-152 web: Your flow credentials file is encrypted using a system-generated key.
May 7 19:03:40 ip-172-31-81-152 web: If the system-generated key is lost for any reason, your credentials
May 7 19:03:40 ip-172-31-81-152 web: file will not be recoverable, you will have to delete it and re-enter
May 7 19:03:40 ip-172-31-81-152 web: your credentials.
May 7 19:03:40 ip-172-31-81-152 web: You should set your own key using the 'credentialSecret' option in
May 7 19:03:40 ip-172-31-81-152 web: your settings file. Node-RED will then re-encrypt your credentials
May 7 19:03:40 ip-172-31-81-152 web: file using your chosen key the next time you deploy a change.
May 7 19:03:40 ip-172-31-81-152 web: ---------------------------------------------------------------------
May 7 19:03:40 ip-172-31-81-152 web: 7 May 19:03:40 - [info] Starting flows
May 7 19:03:41 ip-172-31-81-152 web: 7 May 19:03:41 - [info] Started flows
May 7 19:03:43 ip-172-31-81-152 web: 7 May 19:03:43 - [info] Stopping flows
May 7 19:03:43 ip-172-31-81-152 web: 7 May 19:03:43 - [info] Stopped flows
May 7 19:03:45 ip-172-31-81-152 web: > nova-node-red@1.1.0 start
May 7 19:03:45 ip-172-31-81-152 web: > ./node_modules/.bin/node-red -s ./settings.js
May 7 19:03:47 ip-172-31-81-152 web: prepop flows
May 7 19:03:47 ip-172-31-81-152 web: 7 May 19:03:47 - [info]
May 7 19:03:47 ip-172-31-81-152 web: Welcome to Node-RED
May 7 19:03:47 ip-172-31-81-152 web: ===================
May 7 19:03:47 ip-172-31-81-152 web: 7 May 19:03:47 - [info] Node-RED version: v3.0.2
May 7 19:03:47 ip-172-31-81-152 web: 7 May 19:03:47 - [info] Node.js version: v16.16.0
May 7 19:03:47 ip-172-31-81-152 web: 7 May 19:03:47 - [info] Linux 4.14.287-215.504.amzn2.x86_64 x64 LE
May 7 19:03:47 ip-172-31-81-152 web: 7 May 19:03:47 - [info] Loading palette nodes
May 7 19:03:48 ip-172-31-81-152 web: save settings
May 7 19:03:48 ip-172-31-81-152 web: 7 May 19:03:48 - [info] Settings file : /var/app/current/settings.js
May 7 19:03:48 ip-172-31-81-152 web: 7 May 19:03:48 - [info] Context store : 'default' [module=memory]
May 7 19:03:48 ip-172-31-81-152 web: 7 May 19:03:48 - [info] Server now running at http://127.0.0.1:8080/
May 7 19:03:49 ip-172-31-81-152 web: 7 May 19:03:49 - [warn]
May 7 19:03:49 ip-172-31-81-152 web: ---------------------------------------------------------------------
May 7 19:03:49 ip-172-31-81-152 web: Your flow credentials file is encrypted using a system-generated key.
May 7 19:03:49 ip-172-31-81-152 web: If the system-generated key is lost for any reason, your credentials
May 7 19:03:49 ip-172-31-81-152 web: file will not be recoverable, you will have to delete it and re-enter
May 7 19:03:49 ip-172-31-81-152 web: your credentials.
May 7 19:03:49 ip-172-31-81-152 web: You should set your own key using the 'credentialSecret' option in
May 7 19:03:49 ip-172-31-81-152 web: your settings file. Node-RED will then re-encrypt your credentials
May 7 19:03:49 ip-172-31-81-152 web: file using your chosen key the next time you deploy a change.
May 7 19:03:49 ip-172-31-81-152 web: ---------------------------------------------------------------------
May 7 19:03:49 ip-172-31-81-152 web: 7 May 19:03:49 - [info] Installing module: mongodb, version: latest
May 7 19:03:49 ip-172-31-81-152 web: 7 May 19:03:49 - [info] Installing module: jsonata, version: latest
May 7 19:03:49 ip-172-31-81-152 web: 7 May 19:03:49 - [info] Installing module: @google-cloud/dialogflow, version: latest
May 7 19:03:49 ip-172-31-81-152 web: 7 May 19:03:49 - [info] Installing module: moment, version: latest
May 7 19:03:49 ip-172-31-81-152 web: 7 May 19:03:49 - [info] Installing module: openai, version: latest
May 7 19:13:35 ip-172-31-81-152 web: 7 May 19:13:35 - [error] Installation of module @google-cloud/dialogflow failed:
May 7 19:13:35 ip-172-31-81-152 web: 7 May 19:13:35 - [error] ------------------------------------------
May 7 19:13:35 ip-172-31-81-152 web: 7 May 19:13:35 - [error] npm WARN config production Use `--omit=dev` instead.
May 7 19:13:35 ip-172-31-81-152 web: 7 May 19:13:35 - [error] ------------------------------------------
May 7 19:13:43 ip-172-31-81-152 web: 7 May 19:13:43 - [info] Installed module: moment
May 7 19:13:43 ip-172-31-81-152 web: save settings
May 7 19:13:43 ip-172-31-81-152 web: 7 May 19:13:43 - [info] Installed module: jsonata
May 7 19:13:43 ip-172-31-81-152 web: 7 May 19:13:43 - [info] Installed module: openai
May 7 19:13:43 ip-172-31-81-152 web: 7 May 19:13:43 - [info] Installed module: mongodb
May 7 19:13:43 ip-172-31-81-152 web: 7 May 19:13:43 - [info] Failed to load external modules required by this flow:
May 7 19:13:43 ip-172-31-81-152 web: 7 May 19:13:43 - [info] - @google-cloud/dialogflow [unexpected_error]
May 7 19:13:43 ip-172-31-81-152 web: save settings
May 7 19:13:44 ip-172-31-81-152 web: save settings
May 7 19:13:44 ip-172-31-81-152 web: save settings
May 7 19:14:38 ip-172-31-81-152 web: save settings
May 7 19:14:40 ip-172-31-81-152 web: save flow
May 7 19:14:41 ip-172-31-81-152 web: 7 May 19:14:41 - [info] Stopping flows
May 7 19:14:41 ip-172-31-81-152 web: 7 May 19:14:41 - [info] Stopped flows
May 7 19:14:41 ip-172-31-81-152 web: 7 May 19:14:41 - [info] Updated flows
May 7 19:14:41 ip-172-31-81-152 web: 7 May 19:14:41 - [info] Installing module: jsonata, version: latest
May 7 19:14:41 ip-172-31-81-152 web: 7 May 19:14:41 - [info] Installing module: @google-cloud/dialogflow, version: latest
May 7 19:14:41 ip-172-31-81-152 web: 7 May 19:14:41 - [info] Installing module: moment, version: latest
May 7 19:14:41 ip-172-31-81-152 web: 7 May 19:14:41 - [info] Installing module: openai, version: latest
May 7 19:14:48 ip-172-31-81-152 web: 7 May 19:14:48 - [error] Installation of module jsonata failed:
May 7 19:14:48 ip-172-31-81-152 web: 7 May 19:14:48 - [error] ------------------------------------------
May 7 19:14:48 ip-172-31-81-152 web: 7 May 19:14:48 - [error] npm WARN config production Use `--omit=dev` instead.
May 7 19:14:48 ip-172-31-81-152 web: npm WARN tar ENOENT: Cannot cd into '/var/app/current/node_modules/node-red/node_modules/@node-red/util/node_modules/jsonata'
May 7 19:14:48 ip-172-31-81-152 web: npm WARN tar ENOENT: Cannot cd into '/var/app/current/node_modules/node-red/node_modules/@node-red/util/node_modules/jsonata'
May 7 19:14:48 ip-172-31-81-152 web: npm WARN tarball tarball data for jsonata@https://registry.npmjs.org/jsonata/-/jsonata-1.8.6.tgz (sha512-ZH2TPYdNP2JecOl/HvrH47Xc+9imibEMQ4YqKy/F/FrM+2a6vfbGxeCX23dB9Fr6uvGwv+ghf1KxWB3iZk09wA==) seems to be corrupted. Trying again.
May 7 19:14:48 ip-172-31-81-152 web: npm WARN tarball tarball data for jsonata@https://registry.npmjs.org/jsonata/-/jsonata-1.8.6.tgz (sha512-ZH2TPYdNP2JecOl/HvrH47Xc+9imibEMQ4YqKy/F/FrM+2a6vfbGxeCX23dB9Fr6uvGwv+ghf1KxWB3iZk09wA==) seems to be corrupted. Trying again.
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! code ENOENT
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! syscall lstat
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! path /home/webapp/.npm/_cacache/content-v2/sha512/64/7d/933d874d3f625e70e97f1efac7e3b5dcfbd8a689b10c43862a2b2fc5fc5accfb66babdf6c6c5e097db7741f45afabaf1b0bfe8217f52b1581de2664d3dc0
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! errno -2
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! enoent ENOENT: no such file or directory, lstat '/home/webapp/.npm/_cacache/content-v2/sha512/64/7d/933d874d3f625e70e97f1efac7e3b5dcfbd8a689b10c43862a2b2fc5fc5accfb66babdf6c6c5e097db7741f45afabaf1b0bfe8217f52b1581de2664d3dc0'
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! enoent This is related to npm not being able to find a file.
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! enoent
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! A complete log of this run can be found in:
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! /home/webapp/.npm/_logs/2023-05-07T19_14_43_237Z-debug-0.log
May 7 19:14:48 ip-172-31-81-152 web: 7 May 19:14:48 - [error] ------------------------------------------
May 7 19:14:49 ip-172-31-81-152 web: 7 May 19:14:49 - [info] Installed module: openai
May 7 19:14:49 ip-172-31-81-152 web: 7 May 19:14:49 - [info] Installed module: moment
May 7 19:14:54 ip-172-31-81-152 web: 7 May 19:14:54 - [info] Installed module: @google-cloud/dialogflow
May 7 19:14:54 ip-172-31-81-152 web: save settings
May 7 19:14:54 ip-172-31-81-152 web: 7 May 19:14:54 - [info] Failed to load external modules required by this flow:
May 7 19:14:54 ip-172-31-81-152 web: 7 May 19:14:54 - [info] - jsonata [unexpected_error]
May 7 19:15:07 ip-172-31-81-152 web: save flow
May 7 19:15:08 ip-172-31-81-152 web: 7 May 19:15:08 - [info] Stopping flows
May 7 19:15:08 ip-172-31-81-152 web: 7 May 19:15:08 - [info] Stopped flows
May 7 19:15:08 ip-172-31-81-152 web: 7 May 19:15:08 - [info] Updated flows
May 7 19:15:08 ip-172-31-81-152 web: 7 May 19:15:08 - [info] Installing module: jsonata, version: latest
May 7 19:15:08 ip-172-31-81-152 web: 7 May 19:15:08 - [info] Installing module: moment, version: latest
May 7 19:15:08 ip-172-31-81-152 web: 7 May 19:15:08 - [info] Installing module: openai, version: latest
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [info] Installed module: moment
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [info] Installed module: openai
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [info] Installed module: jsonata
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [info] Starting flows
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:48c52d7356034c3b] Error: Module not allowed
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:25c5f79ba22fe7fd] Error: Module not allowed
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:5d9e23f01c89a776] Error: Module not allowed
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:c3acc92d0cd28f2c] Error: Module not allowed
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:97e57ba62e4e7372] Error: Module not allowed
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:482b532b67055bd2] Error: Module not allowed
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:09884f403104359c] Error: Module not allowed
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:107cc6014eb69b72] Error: Module not allowed
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:a499299e8670eb64] Error: Module not allowed
May 7 19:15:13 ip-172-31-81-152 web: 7 May 19:15:13 - [error] [function:1a5c4ddf0106599e] Error: Module not allowed

```

I think the interesting part is this one;

```auto
May 7 19:14:48 ip-172-31-81-152 web: npm WARN tar ENOENT: Cannot cd into '/var/app/current/node_modules/node-red/node_modules/@node-red/util/node_modules/jsonata'
May 7 19:14:48 ip-172-31-81-152 web: npm WARN tar ENOENT: Cannot cd into '/var/app/current/node_modules/node-red/node_modules/@node-red/util/node_modules/jsonata'
May 7 19:14:48 ip-172-31-81-152 web: npm WARN tarball tarball data for jsonata@https://registry.npmjs.org/jsonata/-/jsonata-1.8.6.tgz (sha512-ZH2TPYdNP2JecOl/HvrH47Xc+9imibEMQ4YqKy/F/FrM+2a6vfbGxeCX23dB9Fr6uvGwv+ghf1KxWB3iZk09wA==) seems to be corrupted. Trying again.
May 7 19:14:48 ip-172-31-81-152 web: npm WARN tarball tarball data for jsonata@https://registry.npmjs.org/jsonata/-/jsonata-1.8.6.tgz (sha512-ZH2TPYdNP2JecOl/HvrH47Xc+9imibEMQ4YqKy/F/FrM+2a6vfbGxeCX23dB9Fr6uvGwv+ghf1KxWB3iZk09wA==) seems to be corrupted. Trying again.
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! code ENOENT
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! syscall lstat
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! path /home/webapp/.npm/_cacache/content-v2/sha512/64/7d/933d874d3f625e70e97f1efac7e3b5dcfbd8a689b10c43862a2b2fc5fc5accfb66babdf6c6c5e097db7741f45afabaf1b0bfe8217f52b1581de2664d3dc0
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! errno -2
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! enoent ENOENT: no such file or directory, lstat '/home/webapp/.npm/_cacache/content-v2/sha512/64/7d/933d874d3f625e70e97f1efac7e3b5dcfbd8a689b10c43862a2b2fc5fc5accfb66babdf6c6c5e097db7741f45afabaf1b0bfe8217f52b1581de2664d3dc0'
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! enoent This is related to npm not being able to find a file.
May 7 19:14:48 ip-172-31-81-152 web: npm ERR! enoent

```

Maybe related to Jsonata being already available to other core nodes like the change node?

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [7 May 2023 20:09 UTC](https://discourse.nodered.org/t/module-not-allowed-for-jsonata/78252/2 "2023-05-07T20:09:19Z")

</div>

Looks like you installed node-red nodes using `sudo`?

```auto
Settings file : /var/app/current/settings.js

```

That is not a normal place. It is possible you therefore have file/folder permissions issues.

Alternatively, you might have had some network errors which corrupted things. If you, you might need to reset and try again.

---

<div class="post-metadata">

**Author:** ![danielterra](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/danielterra/32/75090_2.png) [@danielterra](https://discourse.nodered.org/u/danielterra)\
**Post date:** [7 May 2023 20:16 UTC](https://discourse.nodered.org/t/module-not-allowed-for-jsonata/78252/3 "2023-05-07T20:16:19Z")

</div>

@TotallyInformation i found something strange on the .npmrc file;

```auto
# Force npm to run node-gyp also as root, preventing permission denied errors in AWS with npm@5
unsafe-perm=true

```

Do you this is why it installed as sudo?

This is the package.json of my aplication that im deploying on Elastic Beanstalk;

```auto
{
    "name": "nova-node-red",
    "version": "1.1.0",
    "description": "nova automation node-red instance",
    "main": "",
    "scripts": {
        "start": "./node_modules/.bin/node-red -s ./settings.js"
    },
    "engines": {
        "node": "16.x"
    },
    "dependencies": {
        "@node-red-contrib-themes/theme-collection": "3.0.6",
        "node-red": "3.0.2",
        "node-red-contrib-storage-s3": "0.0.x"
    },
    "author": "",
    "license": "ISC"
}

```

I will try to remove this .npmrc file to see what happens

---

<div class="post-metadata">

**Author:** ![danielterra](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/danielterra/32/75090_2.png) [@danielterra](https://discourse.nodered.org/u/danielterra)\
**Post date:** [7 May 2023 21:31 UTC](https://discourse.nodered.org/t/module-not-allowed-for-jsonata/78252/4 "2023-05-07T21:31:01Z")

</div>

I removed the .npmrc file and created a new enviroment on ELB, i think this folder is the main folder of a ELB machine, it did not changed.

```auto
May 7 21:17:05 ip-172-31-29-183 web: > nova-node-red@1.1.0 start
May 7 21:17:05 ip-172-31-29-183 web: > ./node_modules/.bin/node-red -s ./settings.js
May 7 21:17:06 ip-172-31-29-183 web: prepop flows
May 7 21:17:06 ip-172-31-29-183 web: 7 May 21:17:06 - [info]
May 7 21:17:06 ip-172-31-29-183 web: Welcome to Node-RED
May 7 21:17:06 ip-172-31-29-183 web: ===================
May 7 21:17:06 ip-172-31-29-183 web: 7 May 21:17:06 - [info] Node-RED version: v3.0.2
May 7 21:17:06 ip-172-31-29-183 web: 7 May 21:17:06 - [info] Node.js version: v16.20.0
May 7 21:17:06 ip-172-31-29-183 web: 7 May 21:17:06 - [info] Linux 4.14.311-233.529.amzn2.x86_64 x64 LE
May 7 21:17:07 ip-172-31-29-183 web: 7 May 21:17:07 - [info] Loading palette nodes
May 7 21:17:07 ip-172-31-29-183 web: 7 May 21:17:07 - [info] Settings file : /var/app/current/settings.js
May 7 21:17:07 ip-172-31-29-183 web: 7 May 21:17:07 - [info] Context store : 'default' [module=memory]
May 7 21:17:07 ip-172-31-29-183 web: 7 May 21:17:07 - [info] Server now running at http://127.0.0.1:8080/
May 7 21:17:08 ip-172-31-29-183 web: 7 May 21:17:08 - [warn]

```

this is the first error it throws;

```auto
May 7 21:17:27 ip-172-31-29-183 web: 7 May 21:17:27 - [error] Installation of module openai failed:
May 7 21:17:27 ip-172-31-29-183 web: 7 May 21:17:27 - [error] ------------------------------------------
May 7 21:17:27 ip-172-31-29-183 web: 7 May 21:17:27 - [error] npm WARN config production Use `--omit=dev` instead.
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/uglify-js/tools/domprops.html'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/iconv-lite/encodings/dbcs-codec.js'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/mime/types/other.js'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/iconv-lite/encodings/dbcs-data.js'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/mime/types/standard.js'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/iconv-lite/encodings/index.js'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/iconv-lite/encodings/internal.js'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/iconv-lite/encodings/sbcs-codec.js'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/iconv-lite/encodings/sbcs-data-generated.js'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/iconv-lite/encodings/sbcs-data.js'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, lstat '/var/app/current/node_modules/node-red/node_modules/iconv-lite/.idea/codeStyles'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/iconv-lite/.idea/modules.xml'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, lstat '/var/app/current/node_modules/node-red/node_modules/iconv-lite/.idea/inspectionProfiles'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, lstat '/var/app/current/node_modules/node-red/node_modules/iconv-lite/.idea/codeStyles'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/iconv-lite/.idea/vcs.xml'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/@node-red/nodes/examples/function/delay/01 - Delay message.json'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/@node-red/nodes/examples/function/delay/02 - Delay message by message property.json'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/@node-red/nodes/examples/function/delay/03 - Reset or flush pending message.json'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/@node-red/nodes/examples/function/delay/04 - Limit message rate.json'
May 7 21:17:27 ip-172-31-29-183 web: npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/var/app/current/node_modules/node-red/node_modules/@node-red/nodes/examples/function/delay/05 - Limit message rate for each topic.json'
May 7 21:17:27 ip-172-31-29-183 web: npm ERR! code ENOMEM
May 7 21:17:27 ip-172-31-29-183 web: npm ERR! syscall spawn
May 7 21:17:27 ip-172-31-29-183 web: npm ERR! errno -12
May 7 21:17:27 ip-172-31-29-183 web: npm ERR! spawn ENOMEM
May 7 21:17:27 ip-172-31-29-183 web: npm ERR! A complete log of this run can be found in:
May 7 21:17:27 ip-172-31-29-183 web: npm ERR! /home/webapp/.npm/_logs/2023-05-07T21_17_10_029Z-debug-0.log
May 7 21:17:27 ip-172-31-29-183 web: 7 May 21:17:27 - [error] ------------------------------------------

```

Then i get a bunch of this

```auto
May 7 21:18:21 ip-172-31-29-183 web: 7 May 21:18:21 - [error] [function:carrega o cliente por ID] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:21 ip-172-31-29-183 web: 7 May 21:18:21 - [error] [function:carrega o cliente por ID] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:21 ip-172-31-29-183 web: 7 May 21:18:21 - [error] [function:Carrega sincronizacao] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:21 ip-172-31-29-183 web: 7 May 21:18:21 - [error] [function:Carrega pagamento] Failed to load module : SyntaxError: Unexpected token '}'

```

And finally it crashes with this

```auto
May 7 21:18:21 ip-172-31-29-183 web: 7 May 21:18:21 - [red] Uncaught Exception:
May 7 21:18:21 ip-172-31-29-183 web: 7 May 21:18:21 - [error] /var/app/current/node_modules/node-red/node_modules/jsonata/jsonata.js:7528
May 7 21:18:21 ip-172-31-29-183 web: }
May 7 21:18:21 ip-172-31-29-183 web: ^
May 7 21:18:21 ip-172-31-29-183 web: SyntaxError: Unexpected token '}'
May 7 21:18:21 ip-172-31-29-183 web: at Object.compileFunction (node:vm:360:18)
May 7 21:18:21 ip-172-31-29-183 web: at wrapSafe (node:internal/modules/cjs/loader:1124:15)
May 7 21:18:21 ip-172-31-29-183 web: at Module._compile (node:internal/modules/cjs/loader:1160:27)
May 7 21:18:21 ip-172-31-29-183 web: at Object.Module._extensions..js (node:internal/modules/cjs/loader:1250:10)
May 7 21:18:21 ip-172-31-29-183 web: at Module.load (node:internal/modules/cjs/loader:1074:32)
May 7 21:18:21 ip-172-31-29-183 web: at Function.Module._load (node:internal/modules/cjs/loader:909:12)
May 7 21:18:21 ip-172-31-29-183 web: at ModuleWrap.<anonymous> (node:internal/modules/esm/translators:169:29)
May 7 21:18:21 ip-172-31-29-183 web: at ModuleJob.run (node:internal/modules/esm/module_job:193:25)
May 7 21:18:21 ip-172-31-29-183 web: at async Promise.all (index 0)
May 7 21:18:21 ip-172-31-29-183 web: at async ESMLoader.import (node:internal/modules/esm/loader:530:24)

```

It crash and re-start for 3 times, then finally becomes stable, this is the latest logs;

```auto
May 7 21:18:39 ip-172-31-29-183 web: > nova-node-red@1.1.0 start
May 7 21:18:39 ip-172-31-29-183 web: > ./node_modules/.bin/node-red -s ./settings.js
May 7 21:18:41 ip-172-31-29-183 web: prepop flows
May 7 21:18:41 ip-172-31-29-183 web: 7 May 21:18:41 - [info]
May 7 21:18:41 ip-172-31-29-183 web: Welcome to Node-RED
May 7 21:18:41 ip-172-31-29-183 web: ===================
May 7 21:18:41 ip-172-31-29-183 web: 7 May 21:18:41 - [info] Node-RED version: v3.0.2
May 7 21:18:41 ip-172-31-29-183 web: 7 May 21:18:41 - [info] Node.js version: v16.20.0
May 7 21:18:41 ip-172-31-29-183 web: 7 May 21:18:41 - [info] Linux 4.14.311-233.529.amzn2.x86_64 x64 LE
May 7 21:18:41 ip-172-31-29-183 web: 7 May 21:18:41 - [info] Loading palette nodes
May 7 21:18:42 ip-172-31-29-183 web: 7 May 21:18:42 - [info] Settings file : /var/app/current/settings.js
May 7 21:18:42 ip-172-31-29-183 web: 7 May 21:18:42 - [info] Context store : 'default' [module=memory]
May 7 21:18:42 ip-172-31-29-183 web: 7 May 21:18:42 - [info] Server now running at http://127.0.0.1:8080/
May 7 21:18:43 ip-172-31-29-183 web: 7 May 21:18:43 - [warn]
May 7 21:18:43 ip-172-31-29-183 web: ---------------------------------------------------------------------
May 7 21:18:43 ip-172-31-29-183 web: Your flow credentials file is encrypted using a system-generated key.
May 7 21:18:43 ip-172-31-29-183 web: If the system-generated key is lost for any reason, your credentials
May 7 21:18:43 ip-172-31-29-183 web: file will not be recoverable, you will have to delete it and re-enter
May 7 21:18:43 ip-172-31-29-183 web: your credentials.
May 7 21:18:43 ip-172-31-29-183 web: You should set your own key using the 'credentialSecret' option in
May 7 21:18:43 ip-172-31-29-183 web: your settings file. Node-RED will then re-encrypt your credentials
May 7 21:18:43 ip-172-31-29-183 web: file using your chosen key the next time you deploy a change.
May 7 21:18:43 ip-172-31-29-183 web: ---------------------------------------------------------------------
May 7 21:18:43 ip-172-31-29-183 web: 7 May 21:18:43 - [info] Installing module: moment, version: latest
May 7 21:18:44 ip-172-31-29-183 web: 7 May 21:18:44 - [info] Installed module: moment
May 7 21:18:44 ip-172-31-29-183 web: save settings
May 7 21:18:44 ip-172-31-29-183 web: 7 May 21:18:44 - [info] Starting flows
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [info] Started flows
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:carrega o cliente por ID] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:carrega o cliente por ID] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Carrega sincronizacao] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Carrega pagamento] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Atualiza tags do pagamento] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Carregar habilitacao] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Validar se tem todos os campos] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Carregar template] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Carregar atendido] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Carregar cliente] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Preparar payload whatsapp] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:texto de sucesso] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Criar tarefa de atendimento] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Traduzir dicionario] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Traduzir dicionario] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Adiciona anexos] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:transacao] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:texto de sucesso] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:carrega o cliente por ID] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Traduzir dicionario] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:carrega o cliente por ID] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Linker API Payload] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:carrega o Pessoa Jurídica por CNPJ] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Carregar Conta Bancária por ID de PJ] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Traduzir dicionario] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Pessoa Jurídica por CNPJ (Origem)] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Conta Bancária por ID de PJ (Origem)] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Pessoa Jurídica por CNPJ (Destino)] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Conta Bancária por ID de PJ (Destino)] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Linker API Payload] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Linker API Payload (ano todo)] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:avisa que está indisponível] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Traduzir dicionario] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:carrega o cliente por ID] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Comentário] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Comentário] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Comentário] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Comentário] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:45 ip-172-31-29-183 web: 7 May 21:18:45 - [error] [function:Comentário] Failed to load module : SyntaxError: Unexpected token '}'
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:carrega o cliente por ID] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:carrega o cliente por ID] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Carrega sincronizacao] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Carrega pagamento] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Atualiza tags do pagamento] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Carregar habilitacao] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Validar se tem todos os campos] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Carregar template] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Carregar atendido] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Carregar cliente] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Preparar payload whatsapp] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:texto de sucesso] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Criar tarefa de atendimento] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Traduzir dicionario] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Traduzir dicionario] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Adiciona anexos] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:transacao] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:texto de sucesso] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:carrega o cliente por ID] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Traduzir dicionario] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:carrega o cliente por ID] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Linker API Payload] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:carrega o Pessoa Jurídica por CNPJ] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Carregar Conta Bancária por ID de PJ] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Traduzir dicionario] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Pessoa Jurídica por CNPJ (Origem)] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Conta Bancária por ID de PJ (Origem)] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Pessoa Jurídica por CNPJ (Destino)] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Conta Bancária por ID de PJ (Destino)] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Linker API Payload] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Linker API Payload (ano todo)] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:avisa que está indisponível] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Traduzir dicionario] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:carrega o cliente por ID] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Comentário] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Comentário] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Comentário] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Comentário] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [error] [function:Comentário] Function node failed to load external modules
May 7 21:18:46 ip-172-31-29-183 web: 7 May 21:18:46 - [warn] [function:[Tiny] Solicitar pedidos filtrados] Ultima atualização; 07/05/2023 15:14

```

Now it looks like it is working fine, but im afraid of needing to create a new environment for each time it crashes, i would like to understand what is going on

---

<div class="post-metadata">

**Author:** ![danielterra](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/danielterra/32/75090_2.png) [@danielterra](https://discourse.nodered.org/u/danielterra)\
**Post date:** [9 May 2023 13:47 UTC](https://discourse.nodered.org/t/module-not-allowed-for-jsonata/78252/5 "2023-05-09T13:47:39Z")

</div>

It is woking fine until now, but im not abble to import and use jsonata as a module on the function node, i have found no workaround this

---

<div class="post-metadata">

**Author:** ![danielterra](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/danielterra/32/75090_2.png) [@danielterra](https://discourse.nodered.org/u/danielterra)\
**Post date:** [9 May 2023 16:07 UTC](https://discourse.nodered.org/t/module-not-allowed-for-jsonata/78252/6 "2023-05-09T16:07:37Z")

</div>

I created a account at FlowForge in the hopes of being some mistake i made in my deployment on AWS Elastic Beanstalk, but i got the same result;

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/d/1/d122f5fb2d8505e837269c3c5da02ecb8c934503.jpeg)

It looks like trying to install jsonata breaks something that it should not

```auto
2023-05-09T16:02:56.338Z [err] npm WARN tar
2023-05-09T16:02:56.339Z [err] TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/data/node_modules/jsonata/jsonata-es5.min.js'
2023-05-09T16:02:56.741Z [err] npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/data/node_modules/jsonata/jsonata.js'
2023-05-09T16:02:57.239Z [err] npm WARN
2023-05-09T16:02:57.239Z [err] tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/data/node_modules/jsonata/jsonata.min.js'
2023-05-09T16:02:57.241Z [err] npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/data/node_modules/jsonata/package.json'
2023-05-09T16:02:57.242Z [err] npm WARN 
2023-05-09T16:02:57.242Z [err] tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/data/node_modules/jsonata/README.md'
2023-05-09T16:02:57.438Z [err] npm WARN tar TAR_ENTRY_ERROR ENOENT: no such file or directory, open '/data/node_modules/jsonata/jsonata.d.ts'
2023-05-09T16:03:05.038Z [out] 
2023-05-09T16:03:05.038Z [out] removed 22 packages, changed 1 package, and audited 147 packages in 40s
2023-05-09T16:03:05.038Z [out] 
2023-05-09T16:03:05.038Z [out] 14 packages are looking for funding
2023-05-09T16:03:05.038Z [out] run `npm fund` for details
2023-05-09T16:03:05.038Z [out] 
2023-05-09T16:03:05.038Z [out] found 0 vulnerabilities
2023-05-09T16:03:05.338Z rc=0
2023-05-09T16:03:07.038Z [err] npm
2023-05-09T16:03:07.038Z [err]  
2023-05-09T16:03:07.039Z [err] WARN tar
2023-05-09T16:03:07.039Z [err] ENOENT: Cannot cd into '/data/node_modules/moment'
2023-05-09T16:03:10.137Z [err] npm WARN tar ENOENT: Cannot cd into '/data/node_modules/moment'
2023-05-09T16:03:10.137Z [err] npm WARN tarball tarball data for moment@https://registry.npmjs.org/moment/-/moment-2.29.4.tgz (sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==) seems to be corrupted. Trying again.
2023-05-09T16:03:10.437Z [out] 
2023-05-09T16:03:10.437Z [out] removed 14 packages, changed 9 packages, and audited 155 packages in 46s
2023-05-09T16:03:10.437Z [out] 
2023-05-09T16:03:10.437Z [out] 15 packages are looking for funding
2023-05-09T16:03:10.437Z [out] run `npm fund` for details
2023-05-09T16:03:10.437Z [out] 
2023-05-09T16:03:10.437Z [out] found 0 vulnerabilities
2023-05-09T16:03:11.038Z rc=0
2023-05-09T16:03:11.240Z [err] npm 
2023-05-09T16:03:11.241Z [err] WARN tarball tarball data for moment@https://registry.npmjs.org/moment/-/moment-2.29.4.tgz (sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==) seems to be corrupted. Trying again.
2023-05-09T16:03:11.840Z [err] npm 
2023-05-09T16:03:11.840Z [err] ERR! code ENOENT
2023-05-09T16:03:11.840Z [err] npm ERR! syscall lstat
2023-05-09T16:03:11.840Z [err] npm ERR! 
2023-05-09T16:03:11.840Z [err] path /data/.npm/_cacache/content-v2/sha512/e4/b0/bd48ec6349cd8717abced82cae4c3362bc4768cf622fc892468fa5fc0c9d1e1727eccc4d1088477e897981bd43f7587c528c51ffbc8b00d04374d1c82bf3
2023-05-09T16:03:11.840Z [err] npm ERR! 
2023-05-09T16:03:11.840Z [err] errno -2
2023-05-09T16:03:11.842Z [err] npm ERR! enoent ENOENT: no such file or directory, lstat '/data/.npm/_cacache/content-v2/sha512/e4/b0/bd48ec6349cd8717abced82cae4c3362bc4768cf622fc892468fa5fc0c9d1e1727eccc4d1088477e897981bd43f7587c528c51ffbc8b00d04374d1c82bf3'
2023-05-09T16:03:11.842Z [err] npm ERR! enoent This is related to npm not being able to find a file.
2023-05-09T16:03:11.842Z [err] npm ERR! enoent 
2023-05-09T16:03:11.843Z [err] 
2023-05-09T16:03:11.843Z [err] npm ERR! A complete log of this run can be found in:
2023-05-09T16:03:11.843Z [err] npm ERR! /data/.npm/_logs/2023-05-09T16_02_21_045Z-debug-0.log
2023-05-09T16:03:12.139Z rc=254
2023-05-09T16:03:17.844Z [out] 
2023-05-09T16:03:17.844Z [out] added 3 packages, removed 11 packages, changed 12 packages, and audited 161 packages in 56s
2023-05-09T16:03:17.844Z [out] 
2023-05-09T16:03:17.844Z [out] 14 packages are looking for funding
2023-05-09T16:03:17.844Z [out] run `npm fund` for details
2023-05-09T16:03:17.845Z [out] 
2023-05-09T16:03:17.845Z [out] found 0 vulnerabilities
2023-05-09T16:03:18.044Z rc=0

```

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [8 July 2023 16:08 UTC](https://discourse.nodered.org/t/module-not-allowed-for-jsonata/78252/7 "2023-07-08T16:08:14Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
