Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GH-115983: skip building shared modules for testing under WASI #116528

Merged
merged 5 commits into from
Mar 13, 2024

Conversation

brettcannon
Copy link
Member

@brettcannon brettcannon commented Mar 9, 2024

@brettcannon
Copy link
Member Author

!buildbot wasi

@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @brettcannon for commit 3374fe1 🤖

The command will test the builders whose names match following regular expression: wasi

The builders matched are:

  • wasm32-wasi PR
  • wasm32 WASI 8Core PR
  • wasm32-wasi Non-Debug PR

@erlend-aasland
Copy link
Contributor

Could you instead add these using the PY_STDLIB_MOD_SET_NA macro?

cpython/configure.ac

Lines 7333 to 7410 in b9cb855

dnl Modules that are not available on some platforms
AS_CASE([$ac_sys_system],
[AIX], [PY_STDLIB_MOD_SET_NA([_scproxy])],
[VxWorks*], [PY_STDLIB_MOD_SET_NA([_scproxy], [termios], [grp])],
dnl The _scproxy module is available on macOS
[Darwin], [],
[iOS], [
dnl subprocess and multiprocessing are not supported (no fork syscall).
dnl curses and tkinter user interface are not available.
dnl gdbm and nis aren't available
dnl Stub implementations are provided for pwd, grp etc APIs
PY_STDLIB_MOD_SET_NA(
[_curses],
[_curses_panel],
[_gdbm],
[_multiprocessing],
[_posixshmem],
[_posixsubprocess],
[_scproxy],
[_tkinter],
[grp],
[nis],
[readline],
[pwd],
[spwd],
[syslog],
)
],
[CYGWIN*], [PY_STDLIB_MOD_SET_NA([_scproxy])],
[QNX*], [PY_STDLIB_MOD_SET_NA([_scproxy])],
[FreeBSD*], [PY_STDLIB_MOD_SET_NA([_scproxy])],
[Emscripten|WASI], [
dnl subprocess and multiprocessing are not supported (no fork syscall).
dnl curses and tkinter user interface are not available.
dnl dbm and gdbm aren't available, too.
dnl Emscripten and WASI provide only stubs for pwd, grp APIs.
dnl resource functions (get/setrusage) are stubs, too.
PY_STDLIB_MOD_SET_NA(
[_curses],
[_curses_panel],
[_dbm],
[_gdbm],
[_multiprocessing],
[_posixshmem],
[_posixsubprocess],
[_scproxy],
[_tkinter],
[_xxsubinterpreters],
[_xxinterpchannels],
[_xxinterpqueues],
[grp],
[pwd],
[resource],
[syslog],
)
AS_CASE([$ac_sys_system/$ac_sys_emscripten_target],
[Emscripten/browser*], [
dnl These modules are not particularly useful in browsers.
PY_STDLIB_MOD_SET_NA(
[fcntl],
[readline],
[termios],
)
],
[Emscripten/node*], [],
[WASI/*], [
dnl WASI SDK 15.0 does not support file locking, mmap, and more.
PY_STDLIB_MOD_SET_NA(
[_ctypes_test],
[fcntl],
[mmap],
[termios],
)
]
)
],
[PY_STDLIB_MOD_SET_NA([_scproxy])]
)

@brettcannon
Copy link
Member Author

Could you instead add these using the PY_STDLIB_MOD_SET_NA macro?

Done!

@brettcannon brettcannon enabled auto-merge (squash) March 13, 2024 22:57
@brettcannon brettcannon merged commit 8c094c3 into python:main Mar 13, 2024
36 of 37 checks passed
@brettcannon brettcannon deleted the skip-shared-test-modules-on-wasi branch March 13, 2024 23:25
@vstinner vstinner added the needs backport to 3.12 bug and security fixes label Jun 10, 2024
@miss-islington-app

This comment was marked as outdated.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jun 10, 2024
@bedevere-app
Copy link

bedevere-app bot commented Jun 10, 2024

GH-120316 is a backport of this pull request to the 3.12 branch.

@bedevere-app bedevere-app bot removed the needs backport to 3.12 bug and security fixes label Jun 10, 2024
vstinner pushed a commit that referenced this pull request Jun 10, 2024
…GH-116528) (#120316)

GH-115983: skip building shared modules for testing under WASI (GH-116528)
(cherry picked from commit 8c094c3)

Co-authored-by: Brett Cannon <[email protected]>
@brettcannon
Copy link
Member Author

FYI I purposefully didn't bothering backporting as tier 2 support was only for 3.13 and I have made no guarantees older versions would work with newer WASI SDK versions (there's actually a discussion to be had if they even should as binary wheels wouldn't be compatible w/ different SDK versions).

@vstinner
Copy link
Member

FYI I purposefully didn't bothering backporting as tier 2 support was only for 3.13

The backport was needed to repair the WASI buildbots: regression caused by #120173 backport to 3.12.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants