Skip to content

feat: JS API RspackError support error chain #10383

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

Open
wants to merge 29 commits into
base: main
Choose a base branch
from
Open

Conversation

SyMind
Copy link
Member

@SyMind SyMind commented May 16, 2025

Summary

JsRspackError enhancements:

  • Renamed to RspackError for clarity.
  • Implemented miette::Diagnostic trait for better error handling.
  • Added an error field to expose the underlying error details to JavaScript.

Refactored ModuleBuildError:

  • Source error is now stored as Box<dyn Diagnostic + Sync + Send + 'static>.

New ModuleNotFoundError struct:

  • Stores source errors as Box<dyn Diagnostic + Sync + Send + 'static>.

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

@github-actions github-actions bot added team The issue/pr is created by the member of Rspack. release: feature release: feature related release(mr only) labels May 16, 2025
Copy link

netlify bot commented May 16, 2025

Deploy Preview for rspack canceled.

Name Link
🔨 Latest commit 34c47a0
🔍 Latest deploy log https://app.netlify.com/projects/rspack/deploys/682ec6035542550008be25ac

Copy link

codspeed-hq bot commented May 16, 2025

CodSpeed Performance Report

Merging #10383 will not alter performance

Comparing rspack-error-chain (34c47a0) with main (7033258)

🎉 Hooray! codspeed-rust just leveled up to 2.7.2!

A heads-up, this is a breaking change and it might affect your current performance baseline a bit. But here's the exciting part - it's packed with new, cool features and promises improved result stability 🥳!
Curious about what's new? Visit our releases page to delve into all the awesome details about this new version.

Summary

✅ 11 untouched benchmarks

@SyMind SyMind force-pushed the rspack-error-chain branch from 243b2ca to f79b028 Compare May 17, 2025 12:22
@SyMind SyMind force-pushed the rspack-error-chain branch from f79b028 to 37b356a Compare May 17, 2025 12:22
@SyMind SyMind marked this pull request as ready for review May 19, 2025 04:06
@SyMind SyMind requested a review from jerrykingxyz as a code owner May 21, 2025 11:57
@SyMind SyMind force-pushed the rspack-error-chain branch from 1017ecd to f3ca17f Compare May 21, 2025 12:28
@SyMind SyMind force-pushed the rspack-error-chain branch from 6ff04ee to 94b9e6c Compare May 22, 2025 01:38
@SyMind SyMind force-pushed the rspack-error-chain branch from 800808e to e74e68c Compare May 22, 2025 06:15
@SyMind SyMind force-pushed the rspack-error-chain branch from e74e68c to 34c47a0 Compare May 22, 2025 06:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release: feature release: feature related release(mr only) team The issue/pr is created by the member of Rspack.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant