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

chore: increase try-it version of Awkward to 2.6.4 #3279

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

jpivarski
Copy link
Member

When I check the Pyodide console currently available online, the current version of awkward-cpp is 33:

>>> import awkward_cpp
>>> import pkg_resources
<console>:1: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
>>> pkg_resources.get_distribution("awkward-cpp")
awkward-cpp 33 (/lib/python3.12/site-packages)

This is a little more recent than the awkward-cpp 26 that the Try-it! page is currently pinned to (because if we didn't pin it, it wouldn't get the latest awkward-cpp but would get the latest awkward and there'd be a conflict). Updates are good things, so let's update (from November 2023 to May 2024).

The latest awkward version this corresponds to is 2.6.4:

[project]
name = "awkward_cpp"
version = "33"

This PR ought to give me a "View Deployment" button (it's also a test of that), which I'll want to test before committing to change the documentation. The worst thing is when a public Try-it! page is broken—even being out of date is better.

@jpivarski
Copy link
Member Author

No, this has the wheel spin forever, but in the Javascript console,

Uncaught (in promise) PythonError: Traceback (most recent call last):
  File "/lib/python3.11/site-packages/micropip/_commands/install.py", line 142, in install
    await transaction.gather_requirements(requirements)
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 204, in gather_requirements
    await asyncio.gather(*requirement_promises)
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 211, in add_requirement
    return await self.add_requirement_inner(Requirement(req))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 300, in add_requirement_inner
    await self._add_requirement_from_package_index(req)
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 347, in _add_requirement_from_package_index
    await self.add_wheel(wheel, req.extras, specifier=str(req.specifier))
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 385, in add_wheel
    await self.gather_requirements(wheel.requires(extras))
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 204, in gather_requirements
    await asyncio.gather(*requirement_promises)
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 208, in add_requirement
    return await self.add_requirement_inner(req)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 300, in add_requirement_inner
    await self._add_requirement_from_package_index(req)
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 339, in _add_requirement_from_package_index
    wheel = find_wheel(metadata, req)
            ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/lib/python3.11/site-packages/micropip/transaction.py", line 431, in find_wheel
    raise ValueError(
ValueError: Can't find a pure Python 3 wheel for 'awkward-cpp==33'.
See: https://pyodide.org/en/stable/usage/faq.html#why-can-t-micropip-find-a-pure-python-wheel-for-a-package
You can use `await micropip.install(..., keep_going=True)` to get a list of all packages with missing wheels.

    at new_error (pyodide.asm.js:9:10014)
    at pyodide.asm.wasm:0x158e62
    at pyodide.asm.wasm:0x15ff9e
    at _PyEM_TrampolineCall_JS (pyodide.asm.js:9:120223)
    at pyodide.asm.wasm:0x1a3494
    at pyodide.asm.wasm:0x28a2bd
    at pyodide.asm.wasm:0x1e431e
    at pyodide.asm.wasm:0x1a397d
    at pyodide.asm.wasm:0x1a3c3e
    at pyodide.asm.wasm:0x1a3ce0
    at pyodide.asm.wasm:0x2689a4
    at pyodide.asm.wasm:0x26e800
    at pyodide.asm.wasm:0x1a3e08
    at pyodide.asm.wasm:0x1a3a98
    at pyodide.asm.wasm:0x15f76b
    at Module.callPyObjectKwargs (pyodide.asm.js:9:64297)
    at Module.callPyObject (pyodide.asm.js:9:65365)
    at wrapper (pyodide.asm.js:9:32855)

@agoose77
Copy link
Collaborator

@jpivarski the thing to watch out for here is the version of pyodide that is pulled into the HTML page. Before, we built the WASM wheel ourselves and pulled it in, but now that we rely on the prebuilt distribution, we can only move as fast as the distribution release cadence.

It looks like we can bump to whichever version of Awkward is in 0.26.2 (see https://github.com/scikit-hep/awkward/blob/3d031ca2482c6d9f94f1153aef53e3b772b2406b/docs/_static/try-it.html#L76C58-L76C65)

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.

2 participants