You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm developing a plugin using wazero and I'm trying to use stdio to exchange data between host and plugin.
However, I noticed that the behavior of Read was different from that of a normal Go program.
Normally, Read blocks until calling Write syscall, but when I run the plugin using wazero, it always seems to receive io.EOF .
Similarly, when I call Write API for os.Stdout on the plugin side, it could not be Read properly on the host side.
To Reproduce
I prepared example repository to reproduce this issue.
I expect the plugin's fmt.Fprintf to be called only once, but in fact it is called constantly.
Screenshots
If applicable, add screenshots to help explain your problem.
Environment (please complete the relevant information):
Go version: 1.21.0
wazero Version: v1.7.0
Host architecture: Darwin mc-XJK92G53P9 23.3.0 Darwin Kernel Version 23.3.0: Wed Dec 20 21:30:44 PST 2023; root:xnu-10002.81.5~7/RELEASE_ARM64_T6000 arm64
Runtime mode: compiler
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
Describe the bug
I'm developing a plugin using wazero and I'm trying to use stdio to exchange data between host and plugin.
However, I noticed that the behavior of
Read
was different from that of a normal Go program.Normally,
Read
blocks until callingWrite
syscall, but when I run the plugin using wazero, it always seems to receiveio.EOF
.Similarly, when I call
Write
API foros.Stdout
on the plugin side, it could not beRead
properly on the host side.To Reproduce
I prepared example repository to reproduce this issue.
https://github.com/goccy/wazero-example
Plugin code is here.
Host code is here
Expected behavior
I expect the plugin's
fmt.Fprintf
to be called only once, but in fact it is called constantly.Screenshots
If applicable, add screenshots to help explain your problem.
Environment (please complete the relevant information):
Darwin mc-XJK92G53P9 23.3.0 Darwin Kernel Version 23.3.0: Wed Dec 20 21:30:44 PST 2023; root:xnu-10002.81.5~7/RELEASE_ARM64_T6000 arm64
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: