Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 0 additions & 48 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,48 +19,6 @@ permissions:
pull-requests: write

jobs:
linux:
name: Populate cache
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: "recursive"

- uses: actions/setup-python@v5
with:
python-version: "3.14.0"

- name: Install latest Rust stable toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: wasm32-wasip2
components: clippy, rustfmt

- uses: Swatinem/rust-cache@v2
with:
shared-key: "rust-cache-${{ hashFiles('./Cargo.lock') }}"
cache-on-failure: false

- name: Install WASI-SDK
shell: bash
run: |
cd /tmp
curl -LO https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-${WASI_SDK_VERSION}/wasi-sdk-${WASI_SDK_VERSION}.0-x86_64-linux.tar.gz
tar xf wasi-sdk-${WASI_SDK_VERSION}.0-x86_64-linux.tar.gz
mv wasi-sdk-${WASI_SDK_VERSION}.0-x86_64-linux /opt/wasi-sdk

- name: Build
shell: bash
run: cargo build --release

- name: Upload CPython builddir
uses: actions/upload-artifact@v4
with:
name: cpython-wasi
path: cpython/builddir/wasi

release:
name: Build and release
needs: linux
Expand Down Expand Up @@ -174,12 +132,6 @@ jobs:
shell: bash
run: echo "WASI_SDK_PATH=$(cygpath -m /tmp/wasi-sdk-${WASI_SDK_VERSION}.0-${{ matrix.config.wasiSDK }})" >> ${GITHUB_ENV}

- name: Restore CPython
uses: actions/download-artifact@v5
with:
name: cpython-wasi
path: cpython/builddir/wasi

- name: Build wheels
uses: PyO3/maturin-action@v1
with:
Expand Down
48 changes: 0 additions & 48 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,48 +17,6 @@ env:
WASI_SDK_VERSION: 34

jobs:
linux:
name: Populate cache
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: "recursive"

- uses: actions/setup-python@v5
with:
python-version: "3.14.0"

- name: Install latest Rust stable toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: wasm32-wasip2
components: clippy, rustfmt

- uses: Swatinem/rust-cache@v2
with:
shared-key: "rust-cache-${{ hashFiles('./Cargo.lock') }}"
cache-on-failure: false

- name: Install WASI-SDK
shell: bash
run: |
cd /tmp
curl -LO https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-${WASI_SDK_VERSION}/wasi-sdk-${WASI_SDK_VERSION}.0-x86_64-linux.tar.gz
tar xf wasi-sdk-${WASI_SDK_VERSION}.0-x86_64-linux.tar.gz
mv wasi-sdk-${WASI_SDK_VERSION}.0-x86_64-linux /opt/wasi-sdk

- name: Build
shell: bash
run: cargo build --release

- name: Upload CPython builddir
uses: actions/upload-artifact@v4
with:
name: cpython-wasi
path: cpython/builddir/wasi

test:
name: Test
needs: linux
Expand Down Expand Up @@ -104,12 +62,6 @@ jobs:
shell: bash
run: echo "WASI_SDK_PATH=$(cygpath -m /tmp/wasi-sdk-${WASI_SDK_VERSION}.0-${{ matrix.config.wasiSDK }})" >> ${GITHUB_ENV}

- name: Restore CPython
uses: actions/download-artifact@v5
with:
name: cpython-wasi
path: cpython/builddir/wasi

- name: Lint
shell: bash
run: bash .github/workflows/lint.sh
Expand Down
8 changes: 4 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,16 @@ First, make sure you've got all the submodules cloned.
git submodule update --init --recursive
```

Next, install WASI-SDK 33 to `/opt/wasi-sdk` (alternatively, you can specify a
Next, install WASI-SDK 34 to `/opt/wasi-sdk` (alternatively, you can specify a
different location and reference it later using the `WASI_SDK_PATH` environment
variable). Replace `arm64-linux` with `x86_64-linux`, `arm64-macos`,
`x86_64-macos`, `arm64-windows`, or `x86_64-windows` below depending on your
architecure and OS, if necessary.

```shell
curl -LO https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-33/wasi-sdk-33.0-arm64-linux.tar.gz
tar xf wasi-sdk-33.0-arm64-linux.tar.gz
sudo mv wasi-sdk-33.0-arm64-linux /opt/wasi-sdk
curl -LO https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-34/wasi-sdk-34.0-arm64-linux.tar.gz
tar xf wasi-sdk-34.0-arm64-linux.tar.gz
sudo mv wasi-sdk-34.0-arm64-linux /opt/wasi-sdk
export WASI_SDK_PATH=/opt/wasi-sdk
```

Expand Down
68 changes: 50 additions & 18 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ pyo3 = { version = "0.28.3", features = [
wasmtime = "48.0.0"
wasmtime-wasi = { version = "48.0.0", features = [ "p3" ] }
once_cell = "1.20.2"
component-init-transform = "0.2.0"
# TODO: publish a release to crates.io and use it:
component-init-transform = { git = "https://github.com/dicej/component-init", rev = "d8bad1bf" }
async-trait = "0.1.83"
futures = "0.3.31"
tokio = { version = "1.41.0", features = [
Expand Down
Loading