Stream: git-wasmtime

Topic: wasmtime / Issue #1840 Unable to replace stdin/stdout/std...


view this post on Zulip Wasmtime GitHub notifications bot (Jun 07 2020 at 01:24):

linouxis9 opened Issue #1840:

Because of the following checks: https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/sys/unix/osother.rs#L16
https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/sys/windows/osother.rs#L16

And the fact that an OsOther is used here:
https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/ctx.rs#L372

It is impossible since #1561, to replace stdin/stdout/stderr with a File descriptor pointing to a file.

I had tried fixing this issue by simply replacing OsOther by OsFile:
https://github.com/bytecodealliance/wasmtime/pull/1839/files

But obviously, this does not work as other kinds of fd should also be supported.

What would be the course of action to fix this issue? Allowing OsOther to take a file?

view this post on Zulip Wasmtime GitHub notifications bot (Jun 07 2020 at 01:25):

linouxis9 edited Issue #1840:

Because of the following checks: https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/sys/unix/osother.rs#L16
https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/sys/windows/osother.rs#L16

And the fact that an OsOther is used here:
https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/ctx.rs#L372

It is impossible since #1561, to replace stdin/stdout/stderr with a File descriptor pointing to a file.

I had tried fixing this issue (#1839) by simply replacing OsOther by OsFile, but obviously, this cannot work as other kinds of fd should also be supported.

What would be the course of action to fix this issue? Allowing OsOther to take a file?

view this post on Zulip Wasmtime GitHub notifications bot (Jun 08 2020 at 18:06):

pchickey assigned Issue #1840:

Because of the following checks: https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/sys/unix/osother.rs#L16
https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/sys/windows/osother.rs#L16

And the fact that an OsOther is used here:
https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/ctx.rs#L372

It is impossible since #1561, to replace stdin/stdout/stderr with a File descriptor pointing to a file.

I had tried fixing this issue (#1839) by simply replacing OsOther by OsFile, but obviously, this cannot work as other kinds of fd should also be supported.

What would be the course of action to fix this issue? Allowing OsOther to take a file?

view this post on Zulip Wasmtime GitHub notifications bot (Jun 08 2020 at 18:10):

pchickey commented on Issue #1840:

I believe that #1600 will fix this issue, sorry that it fell off my radar for the past few weeks. We will get it merged as soon as we can.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 08 2020 at 23:19):

linouxis9 commented on Issue #1840:

Indeed, it does!
This issue seems to be a duplicate of #1735, thanks for your work!

view this post on Zulip Wasmtime GitHub notifications bot (Jun 10 2020 at 14:27):

linouxis9 commented on Issue #1840:

Closing issue since #1600 was merged, thank you!

view this post on Zulip Wasmtime GitHub notifications bot (Jun 10 2020 at 14:27):

linouxis9 closed Issue #1840 (assigned to pchickey):

Because of the following checks: https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/sys/unix/osother.rs#L16
https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/sys/windows/osother.rs#L16

And the fact that an OsOther is used here:
https://github.com/bytecodealliance/wasmtime/blob/4bb58940c74c37bdba8630810645cbd41dd0ff7e/crates/wasi-common/src/ctx.rs#L372

It is impossible since #1561, to replace stdin/stdout/stderr with a File descriptor pointing to a file.

I had tried fixing this issue (#1839) by simply replacing OsOther by OsFile, but obviously, this cannot work as other kinds of fd should also be supported.

What would be the course of action to fix this issue? Allowing OsOther to take a file?


Last updated: Nov 22 2024 at 17:03 UTC