File tree Expand file tree Collapse file tree 1 file changed +19
-2
lines changed Expand file tree Collapse file tree 1 file changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -220,10 +220,27 @@ AddType application/wasm wasm
220
220
221
221
# WASI (wasm32-wasi)
222
222
223
- WASI builds require [ WASI SDK] ( https://github.com/WebAssembly/wasi-sdk ) and
224
- currently [ wasix] ( https://github.com/singlestore-labs/wasix ) for POSIX
223
+ WASI builds require [ WASI SDK] ( https://github.com/WebAssembly/wasi-sdk ) 15.0+
224
+ and currently [ wasix] ( https://github.com/singlestore-labs/wasix ) for POSIX
225
225
compatibility stubs.
226
226
227
+ ## WASI limitations and issues (WASI SDK 15.0)
228
+
229
+ A lot of Emscripten limitations also apply to WASI. Noticable restrictions
230
+ are:
231
+
232
+ - Call stack size is limited. Default recursion limit and parser stack size
233
+ are smaller than in regular Python builds.
234
+ - `` socket(2) `` cannot create new socket file descriptors. WASI programs can
235
+ call read/write/accept on a file descriptor that is passed into the process.
236
+ - `` socket.gethostname() `` and host name resolution APIs like
237
+ `` socket.gethostbyname() `` are not implemented and always fail.
238
+ - `` chmod(2) `` is not available. It's not possible to modify file permissions,
239
+ yet. A future version of WASI may provide a limited `` set_permissions `` API.
240
+ - File locking (`` fcntl `` ) is not available.
241
+ - `` os.pipe() `` , `` os.mkfifo() `` , and `` os.mknod() `` are not supported.
242
+
243
+
227
244
# Detect WebAssembly builds
228
245
229
246
## Python code
You can’t perform that action at this time.
0 commit comments