Closed SmartLayer closed 1 year ago
Hi @weiwu-zhang, it seems like you're using mermaid.cli (very outdated (5 years old)), instead of @mermaid-js/mermaid-cli.
You may want to npm uninstall -g mermaid.cli
. If you have a modern version of Node.JS, you can also just use npx @mermaid-js/mermaid-cli
and NPM should auto-install the updated package in a cache directory.
I believe puppeteer will automatically download an ARM64 version on MacOS, but I'm not sure if it will on Linux (see https://github.com/puppeteer/puppeteer/issues/550). However, you can create a puppeteer-config.json
file that has the contents like: {"executablePath": "/usr/bin/chromium-browser"}
, you can then run mmdc --puppeteerConfigFile puppeteer-config.json -i test.mmd
and it should work!
Let me know if you're still having this bug (or a different bug) with the latest version of @mermaid-js/mermaid-cli
, and I'll re-open this issue.
Describe the bug A syntax error in the error handling code.
To Reproduce
Error: Failed to launch chrome! /usr/local/lib/node_modules/mermaid.cli/node_modules/puppeteer/.local-chromium/linux-686378/chrome-linux/chrome: 1: Syntax error: Unterminated quoted string
TROUBLESHOOTING: https://github.com/GoogleChrome/puppeteer/blob/master/docs/troubleshooting.md
Node.js v18.13.0