mermaid-filter
mermaid-filter copied to clipboard
Unhandled promise rejection (rejection id: 1): Error: spawn EACCES fs.js:1112
I am running pandoc v.2.0.5 (Compiled with pandoc-types 1.17.3, texmath 0.10, skylighting 0.5) on Debian.
If I run
pandoc -t html -F mermaid-filter -o something.html test.md
on the example file in the repository, I get
(node:19032) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: spawn EACCES fs.js:1112 return binding.unlink(pathModule._makeLong(path)); ^
Error: ENOENT: no such file or directory, unlink '/tmp/tmp-19025tExPUzZBsx4v.tmp.png' at Error (native) at Object.fs.unlinkSync (fs.js:1112:18) at mv (/usr/lib/node_modules/mermaid-filter/index.js:102:8) at mermaid (/usr/lib/node_modules/mermaid-filter/index.js:73:9) at /usr/lib/node_modules/mermaid-filter/node_modules/pandoc-filter/index.js:52:19 at Array.forEach (native) at walk (/usr/lib/node_modules/mermaid-filter/node_modules/pandoc-filter/index.js:50:7) at /usr/lib/node_modules/mermaid-filter/node_modules/pandoc-filter/index.js:74:16 at Array.forEach (native) at walk (/usr/lib/node_modules/mermaid-filter/node_modules/pandoc-filter/index.js:73:20) Error running filter mermaid-filter: Filter returned error status 1
Any idea where the trouble could come from?
See this comment on https://github.com/raghur/mermaid-filter/issues/17
Perhaps you could try the fix in the subsequent comment.
Thanks for the suggestion. I did edit the package.json file to add v0.13.0 of puppeteer as a dependency, i.e., the file now ends with:
"pandoc-filter": "^0.1.3",
"tmp": "0.0.28",
"puppeteer": "0.13.0"
}
}
I then ran (as root)
npm update --global
But that didn't changed the error message.
.....include v0.13.0 of puppeteer within the mermaid.cli....
I think you need to hand-edit the package.json for mermaid.cli
Unfortunately, this is an upstream issue and for whatever reason, they've closed the bug without fixing it.