Comments (6)
After trial and errors, much searching on the Internet there's a solution: use Node version > 16
On Windows I've got 14? on Ubuntu 12. None of these worked. After installing Node 16 it finally worked.
Thanks for your efforts to help!
from email-forward-parser.
Glad you found the issue! I'll enforce the minimum required Node version via the package.json
from email-forward-parser.
Hey!
The line require("./email-forward-parser");
makes me think that you didn't install the library via npm.
This means that the required dependencies (re2
) were not installed, hence the error.
So in that case, you need to manually install the required dependencies:
cd ./email-forward-parser
npm i
from email-forward-parser.
Thank you for a quick answer. Unfortunately, after installation of these commands i still bump into the error below
> [email protected] install C:\Users\dmitry\Desktop\email-forward-parser\node_modules\re2
> install-from-cache --artifact build/Release/re2.node --host-var RE2_DOWNLOAD_MIRROR --skip-path-var RE2_DOWNLOAD_SKIP_PATH --skip-ver-var RE2_DOWNLOAD_SKIP_VER || npm run rebuild
Trying https://github.com/uhop/node-re2/releases/download/1.20.3/win32-x64-83.br ...
Trying https://github.com/uhop/node-re2/releases/download/1.20.3/win32-x64-83.gz ...
Building locally ...
> [email protected] rebuild C:\Users\dmitry\Desktop\email-forward-parser\node_modules\re2
> node-gyp rebuild
C:\Users\dmitry\Desktop\email-forward-parser\node_modules\re2>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" rebuild )
I dived into the problem, and due to this problem node-gyp installation problem, it's hard to install node-gyp on Windows.
So I'll try to do it in Docker container
from email-forward-parser.
Good Github repo to create simple API in Docker and start fast
from email-forward-parser.
Unfortunately, still can't install this library. I downloaded VM Ubuntu. When install re2 manually, it writes:
dmitry@dmitry:~/Desktop/email-fwd/node_modules/re2$ npm run install
> [email protected] install
> install-from-cache --artifact build/Release/re2.node --host-var RE2_DOWNLOAD_MIRROR --skip-path-var RE2_DOWNLOAD_SKIP_PATH --skip-ver-var RE2_DOWNLOAD_SKIP_VER || npm run rebuild
Trying https://github.com/uhop/node-re2/releases/download/1.20.3/linux-x64-72.br ...
Trying https://github.com/uhop/node-re2/releases/download/1.20.3/linux-x64-72.gz ...
Building locally ...
> [email protected] rebuild
> node-gyp rebuild
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | linux | x64
gyp info find Python using Python version 3.10.12 found at "/usr/bin/python3"
gyp ERR! UNCAUGHT EXCEPTION
gyp ERR! stack /home/dmitry/Desktop/email-fwd/node_modules/minipass-fetch/node_modules/minipass/dist/cjs/index.js:286
gyp ERR! stack this.emit('abort', this[SIGNAL]?.reason);
gyp ERR! stack ^
gyp ERR! stack
gyp ERR! stack SyntaxError: Unexpected token '.'
gyp ERR! stack at wrapSafe (internal/modules/cjs/loader.js:915:16)
gyp ERR! stack at Module._compile (internal/modules/cjs/loader.js:963:27)
gyp ERR! stack at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
gyp ERR! stack at Module.load (internal/modules/cjs/loader.js:863:32)
gyp ERR! stack at Function.Module._load (internal/modules/cjs/loader.js:708:14)
gyp ERR! stack at Module.require (internal/modules/cjs/loader.js:887:19)
gyp ERR! stack at require (internal/modules/cjs/helpers.js:74:18)
gyp ERR! stack at Object.<anonymous> (/home/dmitry/Desktop/email-fwd/node_modules/minipass-fetch/lib/index.js:6:22)
gyp ERR! stack at Module._compile (internal/modules/cjs/loader.js:999:30)
gyp ERR! stack at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
gyp ERR! System Linux 6.2.0-32-generic
gyp ERR! command "/usr/bin/node" "/home/dmitry/Desktop/email-fwd/node_modules/.bin/node-gyp" "rebuild"
gyp ERR! cwd /home/dmitry/Desktop/email-fwd/node_modules/re2
gyp ERR! node -v v12.22.9
gyp ERR! node-gyp -v v9.4.0
gyp ERR! Node-gyp failed to build your package.
gyp ERR! Try to update npm and/or node-gyp and if it does not help file an issue with the package author.
(node:7629) UnhandledPromiseRejectionWarning: 7
(node:7629) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:7629) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code
Have you faced this error before?
from email-forward-parser.
Related Issues (14)
- Python version? HOT 1
- Outsource regexes? HOT 2
- GMail Plain Text Wrapping HOT 3
- Mails with blocks added after underscore are not correctly managed HOT 10
- base64 encoded emails HOT 2
- Go port HOT 2
- Multiple re2 installations, should be a peer dependency HOT 4
- Outlook Desktop does not parse the forwarded email HOT 11
- Would it be possible to get the layered forwarded emails? HOT 3
- Add types for the library HOT 1
- error while importing package HOT 5
- Running this package with node18 in aws lambda results in GCLIB errors HOT 2
- Improve coverage of IONOS by 1 & 1 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from email-forward-parser.