mermaid-export icon indicating copy to clipboard operation
mermaid-export copied to clipboard

Unable to export image

Open rcasey212 opened this issue 5 years ago • 5 comments

Running on MacOS Mojave 10.14.6

Here is the log from the console:

Installing mermaid.cli...
+ [email protected]
added 1 package from 2 contributors, updated 8 packages and audited 53 packages in 8.194s

found 0 vulnerabilities


Mermaid Export ready

cwd:/
command:/Users/rcasey/.vscode/extensions/gruntfuggly.mermaid-export-0.0.8/node_modules/.bin/mmdc -t default -i "/Users/rcasey/Desktop/rps_flatten/MovingDataToS3Bucket.mmd" -o "/Users/rcasey/Desktop/rps_flatten/MovingDataToS3Bucket.png"
(node:37972) UnhandledPromiseRejectionWarning: Error: Chromium revision is not downloaded. Run "npm install" or "yarn install"
    at Launcher.launch (/Users/rcasey/.vscode/extensions/gruntfuggly.mermaid-export-0.0.8/node_modules/puppeteer/lib/Launcher.js:119:15)
(Use `node --trace-warnings ...` to show where the warning was created)

(node:37972) 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:37972) [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.

Please let me know if you need anything else. Thanks!

rcasey212 avatar Aug 20 '20 16:08 rcasey212

I ran into the same issue, and did this:

cd /Users/rcasey/.vscode/extensions/gruntfuggly.mermaid-export-0.0.8/ && yarn install

and it solved! (It should be done automatically IMHO)

ndac-todoroki avatar Dec 10 '20 17:12 ndac-todoroki

I ran into the same issue, and did this:

cd /Users/rcasey/.vscode/extensions/gruntfuggly.mermaid-export-0.0.8/ && yarn install

and it solved! (It should be done automatically IMHO)

Fabulous! This helped me.

adventurist avatar Oct 20 '21 16:10 adventurist

This file has a very old version of mermaid-cli, so I needed the following

yarn remove mermaid.cli
yarn add @mermaid-js/mermaid-cli

And on Debian derived linux PCs its yarnpkg instead of yarn

BeastyBlacksmith avatar Feb 09 '22 10:02 BeastyBlacksmith

If you have npm but not yarn

cd ~/.vscode/extensions/gruntfuggly.mermaid-export-0.0.8/
npm rm mermaid.cli
npm add mermaid.cli

andresrinivasan avatar Sep 21 '23 22:09 andresrinivasan

If you have npm but not yarn

cd ~/.vscode/extensions/gruntfuggly.mermaid-export-0.0.8/
npm rm mermaid.cli
npm add mermaid.cli

I'm getting this error please help; cwd:/ command:mmdc -t default -i "extension-output-Gruntfuggly.mermaid-export-#1-Mermaid Export" -o "extension-output-Gruntfuggly.png" /bin/sh: 1: mmdc: not found

OK

abdul-devops01 avatar Aug 23 '24 09:08 abdul-devops01