Skip to content

gh-127146: Update test skips for Emscripten 4.0.1 #129375

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

Merged
merged 2 commits into from
Jan 28, 2025

Conversation

hoodmane
Copy link
Contributor

@hoodmane hoodmane commented Jan 27, 2025

PR emscripten-core/emscripten#23306 fixed stating pipes and will be released as part of Emscripten 4.0.2. I removed skips for various other testes that were fixed in 4.0.1 or earlier.

@bedevere-app bedevere-app bot added awaiting review tests Tests in the Lib/test dir labels Jan 27, 2025
@hoodmane hoodmane requested a review from freakboy3742 January 27, 2025 17:40
@hoodmane hoodmane changed the title Update test skips for Emscripten 4.0.1 gh-127146: Update test skips for Emscripten 4.0.1 Jan 27, 2025
@hoodmane hoodmane force-pushed the emscripten-skips-for-4.0.1 branch from 9c27f1f to e2a80f3 Compare January 27, 2025 17:41
Copy link
Contributor

@freakboy3742 freakboy3742 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All makes sense; the only issue preventing merge is the RTD build failure... not sure what is going on there. I'll poke around and see what I can find out.

@zware
Copy link
Member

zware commented Jan 28, 2025

Dumb question, but can the Emscripten version be detected so as to skip based on that version? I think there's prior art for this for various other platforms.

@freakboy3742
Copy link
Contributor

Dumb question, but can the Emscripten version be detected so as to skip based on that version? I think there's prior art for this for various other platforms.

It almost certainly can be; but it will require the analog of platform.ios_ver()/platform.mac_ver() (et al) to expose the platform version identity. I imagine platform.emscripten_ver() (or wasm_ver, if there's an opportunity to share with WASI) will eventually exist; but it doesn't yet.

@freakboy3742 freakboy3742 enabled auto-merge (squash) January 28, 2025 00:43
@freakboy3742 freakboy3742 merged commit 8e57877 into python:main Jan 28, 2025
37 checks passed
@hoodmane hoodmane deleted the emscripten-skips-for-4.0.1 branch January 28, 2025 09:50
@hoodmane
Copy link
Contributor Author

We have sys._emscripten_info.emscripten_version. So we could add the following to support:

def is_emscripten_lt(ver):
   if not is_emscripten:
      return False
   ver_tuple = tuple(int(x) for x in ver.split("."))
   return sys._emscripten_info.emscripten_version < ver_tuple

and then put skipIf(is_emscripten_lt("4.0.1")).

@freakboy3742
Copy link
Contributor

We'll eventually want to surface the version in platform for consistency, rather than the semi-private name on _sys. I'd also suggest using a tuple, rather than parsing the string at runtime,

We could also consider making this a feature of is_emscripten , so that skipIf(is_emscripten()) is "skip any version" and skipIf(is_emscripten((4,0,1)) does an additional version check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip news tests Tests in the Lib/test dir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants