trunk icon indicating copy to clipboard operation
trunk copied to clipboard

Runtime Memory Error after Trunk Build (0.20.3)

Open mainstreamstudios opened this issue 1 year ago • 3 comments

Hello! I encountered a runtime error when using Trunk 0.20.3, installed via cargo install trunk. The error only appeared when running after having built using a GitHub Actions workflow, not during local builds. When reverting to Trunk 0.20.2, the workflow worked fine.

Error Details:

"/rust/deps/dlmalloc-0.2.6/src/dlmalloc.rs:1198:13: assertion failed: psize <= size + max_overhead

Stack:

Error at imports.wbg.__wbg_new_abda76e883ba8a5f "

Workflow Configuration:

  - name: Install Trunk 0.20.3
    run: |
      cargo install trunk
      
 - name: Build project
    run: |
      cd $GITHUB_WORKSPACE
      RUSTFLAGS="-D unused-must_use" cargo build --target wasm32-unknown-unknown --release
      trunk build --release

The 0.20.2 binary worked without issues, while 0.20.3 caused this runtime problem. Appears to be something related to the integrity hashing or nonce.

Also noticed some release configurations added to Cargo.toml that I did not add that may have contributed but unsure of that.

Any insights on this discrepancy or potential fixes would be greatly appreciated. Thanks!

mainstreamstudios avatar Aug 20 '24 15:08 mainstreamstudios

Hm, interesting. Can you create a small reproducer?

ctron avatar Aug 26 '24 06:08 ctron

related issue upstream: https://github.com/rust-lang/rust/issues/124671

DougAnderson444 avatar Jan 12 '25 18:01 DougAnderson444

@DougAnderson444 : does it work now or do you have a reproducer at hand, that would be helpful. did a look into the diff help? thanks

duke-m avatar May 12 '25 20:05 duke-m