-
Notifications
You must be signed in to change notification settings - Fork 42
Preview pane throws an exception when Asciidoctor is trying to write something to stdout #159
Comments
Have you try with my new branch? Works on Linux. |
Your new branch ? I'm using version 2.1.2
Do you have any message on the developer console ?
|
I got a warning:
|
Ok thanks, I will test on an other machine with Windows 7 |
reproduces with Win7 |
another way to crash: [source, js]
----
console.log("toto") <2>
----
<1> test I confirm the problem: each time Asciidoctor.js is trying to write something to stdout... |
Waiting for asciidoctor/asciidoctor.js#187 |
electron/electron#2033 (comment) I think I can workaround this issue in Opal with a fallback on |
It's exactly what I'm trying to do! But Opal produce very obscure code... |
I think the easiest way to provide an Electron implementation is to create a new Then you'll need to detect that you are running in an Electron environment and Let me know if you have any questions. We could even show a (Tray)[http://electron.atom.io/docs/api/tray/] or a (Dialog)[http://electron.atom.io/docs/api/dialog/] to display the error/warning message 😄 |
Is it possible to provided a external custom extension point for IO ? |
To know if it's electron: |
It's a choice to not use notification/tray/dialog because it's not the role of the preview to do that. |
For now, I have made a workaround with a hook of Node's standard stream. see #175. |
Description
Preview pane throws an exception when Asciidoctor is trying to write something to stdout.
Screenshots
Syntax example
Stack trace
I don't really know why the method
warn
is calling in the endfs.writeSync
(see the stack trace below).Operation is not permitted on Windows but maybe this is working on Linux ? (I'm using Windows 10 on this machine)
The text was updated successfully, but these errors were encountered: