wgpu icon indicating copy to clipboard operation
wgpu copied to clipboard

wasm-pack test broken

Open codewiz opened this issue 1 year ago • 4 comments

Description

The recommended command-line to run tests with WebGL fails to parse the top-level Cargo.toml file:

~/src/wgpu% wasm-pack test --headless --chrome --no-default-features --features webgl --workspace
Error: failed to parse manifest: /home/bernie/src/wgpu/Cargo.toml
Caused by: failed to parse manifest: /home/bernie/src/wgpu/Cargo.toml
Caused by: TOML parse error at line 1, column 1
 1 | [workspace]
   | ^ missing field `package`

Platform

  • webgpu trunk as of Jun 11 2024
  • wasm-pack 0.12.1
  • cargo 1.76.0 (c84b36747 2024-01-18)

codewiz avatar Jun 11 '24 20:06 codewiz

You need cd into any crate first. wasm-pack test can't deal with a virtual workspace.

cwfitzgerald avatar Jun 12 '24 02:06 cwfitzgerald

We should better document this.

cwfitzgerald avatar Jun 12 '24 02:06 cwfitzgerald

You need cd into any crate first.

Tiny nitpick: cd isn't strictly necessary; you can also do wasm-pack test <flags> some-package-directory/.

kpreid avatar Jun 12 '24 17:06 kpreid

On my side, wasm-pack headless test cannot succeed to request adapter, while in browser it fails to compute on gpu with a BufferAsyncError

0x8f701 avatar Aug 14 '24 02:08 0x8f701