Commit Graph

2835 Commits

Author SHA1 Message Date
Bart Broere 2f27188ae9
Numpy patch release 1.24.3 (#3790) 2023-04-24 10:25:24 +09:00
Hood Chatham 4e7d1bd834
MAINT apply upgrade_pythoncapi (#3789) 2023-04-23 15:41:37 +09:00
Bart Broere 9f5b9a8cb7
Add a convenience method to pyfetch for the response headers (#2078)
Co-authored-by: Gyeongjae Choi <def6488@gmail.com>
2023-04-21 10:52:36 +02:00
Gyeongjae Choi 2f9d689b88
DOC Hide disabled packages from docs (#3778)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-04-21 10:51:27 +02:00
Gyeongjae Choi 17844abdf7
Re-enable sparseqr (#3783) 2023-04-21 09:25:55 +09:00
Gyeongjae Choi 17f199060b
Fix S3 xbuildenv deploy (#3782) 2023-04-20 11:34:22 +09:00
Deepak Cherian 412e082431
Update xarray to 2023.04.1 (#3779) 2023-04-19 15:57:39 +09:00
Gyeongjae Choi 25ba93485a
Deploy top-of-tree xbuildenv and pyodide-core to S3 (#3766) 2023-04-17 14:22:07 +09:00
Deepak Cherian 9c28f51526
Update to xarray 2023.04.0 (#3773) 2023-04-15 09:16:54 +09:00
Hood Chatham 8f2711f3ce
Update changelog for v0.23.1 (#3769) 2023-04-14 19:54:10 +09:00
Christian Clauss 4a0ca4ed48
Create tools/docker_image_tag.py (#3758)
[skip ci]
2023-04-14 08:51:30 +02:00
Hood Chatham 521e81e88e
In pyodide venv, redirect python -m pip to run in host environment (#3761) 2023-04-13 22:51:10 -07:00
Hood Chatham 4f392d22a8
Fix out of tree pip (#3767) 2023-04-13 22:50:49 -07:00
Hood Chatham f2b2a17d2f
Make executables installed in Pyodide venv run in Pyodide not in host (#3752)
pip can't run inside of Pyodide because it needs to do stuff like make requests
that don't work inside the virtual environment. So the virtual environment bin
folder contains a python-host executable which is a symlink to the
sys.executable that created the virtual environment. The shebang for pip uses
python-host. But then when pip installs an executable it uses sys.executable to
create the shebang for the installed executable. If that is python-host then the
installed executable will run outside of Pyodide. So we need to patch
`sys.executable` to point to the Pyodide Python.
2023-04-12 17:47:20 +02:00
Hood Chatham b1405ffede
Pass the source and build directory explicitly, don't use chdir (#3746)
This switches to passing the source and build directories as arguments.
It adds an output-directory argument to pyodide build allowing us to
indicate where the output wheel should go independent of the build
directory. I also did some cleanup of the logic added in #3310
2023-04-12 17:43:57 +02:00
Christian Clauss b2201c19b1
Upgrade to Python v3.11.3 (#3741) 2023-04-12 17:38:05 +02:00
Loïc Estève 7193109f4d
Package OpenBLAS and use OpenBLAS in scipy (#3331) 2023-04-11 21:30:07 -07:00
Gyeongjae Choi 862163ece3
Add python_stdlib.zip to xbuildenv (#3760)
Resolves #3730
2023-04-12 06:14:18 +02:00
Hood Chatham e309dfdad4
Move mypy to the end of pre-commit (#3755)
Mypy is much slower than any of the other checks so it should go last.
2023-04-11 18:42:55 +02:00
Hood Chatham 77c9ded2c1
More improvements to JsProxy_compute_typeflags (#3750)
This is a followup to #3740 which rearranges the logic a bit more on further consideration.

I found out that if you create a revocable Proxy and then revoke it, a huge number of browser
internal operations raise TypeErrors. Such an object is thus an excellent stress test for our
handling of explosive objects. Overall we do quite well, `isPyProxy` and `compute_type_flags`
are actually the only spots where we run into trouble (and `PyProxy_Check` is the only spot
that is raising a fatal error).

This changes it so that an object with a `length` getter that throws an error or returns
not an integer will have a `__len__` in Python that always throws an error. It can't check
the type anymore because it avoids invoking getters so if the result is a return value from
a getter it won't know the type. The same is true for the `Error.name`, `Error.message`, and
`Error.stack` fields.

To check for methods, I still use `typeof x[method] === "function"`, invoking the getter.
Usually functions don't have getters anyways and I think it is weirder to have false positives
in this case. If there is a getter and it raises an error, we catch it and throw it away.
2023-04-11 09:15:55 -07:00
Loïc Estève 5db237d482
Update libmpfr version and use ftp.gnu.org (#3756) 2023-04-11 14:45:12 +00:00
Gyeongjae Choi f1cc7c622e
Remove CMAKE_INSTALL_PREFIX (#3754)
Resolves #3753
2023-04-11 07:24:33 +02:00
Hood Chatham 0c458f4469
ENH Add then, catch, and finally_ to the Tasks too (#3748) 2023-04-11 07:09:06 +02:00
Gyeongjae Choi 6213477940
Make sure PYODIDE_ROOT points to absolute path in out-of-tree build (#3751) 2023-04-11 13:05:11 +09:00
Hood Chatham 873ca14986
Make SET_FLAG_IF more paranoid (#3740)
This fixes a regression introduced in #3283. 
To be properly paranoid we should assume that each property access can raise an error.
If an error is raised, throw it away and don't set the flag.
This could be further improved to avoid some getter calls but this a start.
2023-04-08 17:14:21 -07:00
Hood Chatham b22731f34d
Switch to mpfr mirror (#3749)
Build is failing because the ssl certificate for mpfr.loria.fr expired. This switches to a mirror.
2023-04-08 17:11:52 -07:00
Hood Chatham d5d2396f6a
Fix set_build_environment so that it works even if HOME is unset (#3744)
I'm running into a crash in cibuildwheel where some of its CI environments don't set HOME. This fixes set_build_environment to be a bit more resistant against crashes due to missing environment variables.
2023-04-08 19:34:10 +02:00
Luiz Irber 24f839a2f2
New package: sourmash (and deps) (#3635)
Add sourmash (Python + Rust extension, packaged with maturin) and missing pure-wheel deps (screed, bitstring, cachetools, deprecation).

After a couple of fixes in sourmash-bio/sourmash#2433 I managed to build it out-of-tree, would like to have it available here to make it easier to distribute (while PyPI doesn't support emscripten wheels).
2023-04-07 20:11:30 -07:00
Gyeongjae Choi 5a8ecf130a
Add `xbuildenv create` CLI command and remove old entrypoints (#3732)
Add a private pyodide xbuildenv create CLI commad that replaces pyodide-build create_xbuildenv. Also removes legacy entrypoints: `pyodide-build {create,install}_xbuildenv.
2023-04-07 20:54:11 +09:00
Hood Chatham 2887a24090
Add an environment variable to mount extra directories into pyodide python command (#3742)
Helpful for build systems which place stuff in temp folders. I'm working on cibuildwheel support which needs this.
2023-04-07 20:28:36 +09:00
Hood Chatham a038ac17d5
Make internal error picklable (#3739) 2023-04-05 11:57:34 +00:00
Loïc Estève ed05037a82
DOC Add missing quote in DBFLAGS (#3735) 2023-04-03 08:16:35 -07:00
Roman Yurchak 8be4402e4f
Fix passing compression-level in `pyodide py-compile` CLI (#3727)
The compression-level wasn't passed through in the internal functions when the target is a single archive.
2023-04-03 16:08:26 +09:00
Hanno Rein 8464064b41
Update rebound and reboundx (#3725) 2023-04-01 17:37:30 -07:00
Hood Chatham 32ccad8f6e
Use upstream libffi (#3629) 2023-04-01 17:32:38 -07:00
Hood Chatham 48cf29f75d
Detect when PyProxies are used with the GIL released and raise an error (#3719)
Resolves #3717.

Before:

```js
$ tstate = pyodide._module._PyEval_SaveThread()
$ pyodide.globals.get("x")
Pyodide has suffered a fatal error. Please report this to the Pyodide maintainers.
The cause of the fatal error was:
RuntimeError: memory access out of bounds
```

After:

```js
$ tstate = pyodide._module._PyEval_SaveThread()
$ pyodide.globals.get("x")
Uncaught NoGilError: Attempted to use PyProxy when Python GIL not held
```
2023-04-01 20:27:49 +02:00
David Lechner 687989c1b5
export python_stdlib.zip in package.json (#3723)
v0.23.0 changed which binary files are needed (removed pyodide_py.tar and pyodide.asm.data and added python_stdlib.zip). The old files were removed from the exports but the new file was not added to the exports.
2023-04-01 20:33:56 +09:00
Roman Yurchak c7168bf112
Remove pyparsing dependency in packaging (#3726)
We forgot to remove it when updating packaging.
2023-04-01 20:26:11 +09:00
Hood Chatham 3e05af6963
Using esbuild instead of rollup (take 2) (#3720)
Co-authored-by: webreflection <andrea.giammarchi@gmail.com>
2023-03-31 09:30:04 +02:00
Roman Yurchak 3446d2e0a1
Bump main to 0.24.0.dev0 (#3721) 2023-03-31 09:29:32 +02:00
Roman Yurchak 53de1c3e72
Version 0.23.0 (#3712) 2023-03-30 23:30:18 +02:00
chrysn 2b20b2b0d0
Add package cbor-diag (#3715) 2023-03-30 20:54:28 +02:00
Roman Yurchak 49caa889da
Fix content compression in the deployment script (#3716) 2023-03-30 20:48:19 +02:00
Gyeongjae Choi 2046310460
ENH Support SDL-based packages and add pyxel (#3508)
Co-authored-by: Hood Chatham <roberthoodchatham@gmail.com>
Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
2023-03-30 08:18:31 +00:00
Roman Yurchak 7f4f66b34b
Deploy py-compiled build (#3701)
Co-authored-by: Hood Chatham <roberthoodchatham@gmail.com>
2023-03-29 22:54:46 +02:00
Roman Yurchak bce105bd69 Revert "Using esbuild instead of rollup (#3679)"
This reverts commit be12f07ed9.
2023-03-29 22:08:03 +02:00
Roman Yurchak 0a1d87d45f
Customize build type in indexURL used by console.html (#3702)
[skip ci]
2023-03-29 22:06:59 +02:00
Roman Yurchak 0714afd3b6
More package updates + micropip 0.3.0 (#3709) 2023-03-29 16:28:42 +02:00
Hood Chatham 0579db7e2e
Update all packages (#3685)
Co-authored-by: Roman Yurchak <rth.yurchak@gmail.com>
2023-03-29 10:39:43 +02:00
Hood Chatham 4f13ab1465
Make PyProxy of async iterator JavaScript async iterables (#3708) 2023-03-29 08:29:16 +02:00