Skip to content

fix: file dependencies are lost when css module fails#8328

Merged
LingyuCoder merged 3 commits intomainfrom
fix/file-dependencies-lost
Nov 5, 2024
Merged

fix: file dependencies are lost when css module fails#8328
LingyuCoder merged 3 commits intomainfrom
fix/file-dependencies-lost

Conversation

@LingyuCoder
Copy link
Copy Markdown
Contributor

@LingyuCoder LingyuCoder commented Nov 4, 2024

Summary

Fix #8075

There are two bugs here:

  1. When a module fails to compile in js loaders, its loaderContext is not merged, so the dependencies added through loaderContext.addDependency are lost.
  2. When there are failed outputs being run in the module executor, as throwing an error directly blocks the subsequent process, the file dependencies are not added to the main compilation.

Checklist

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

@github-actions github-actions bot added release: bug fix release: bug related release(mr only) team The issue/pr is created by the member of Rspack. labels Nov 4, 2024
@netlify
Copy link
Copy Markdown

netlify bot commented Nov 4, 2024

Deploy Preview for rspack canceled.

Name Link
🔨 Latest commit d53c14e
🔍 Latest deploy log https://app.netlify.com/sites/rspack/deploys/67299f052bdad100080d4780

@LingyuCoder LingyuCoder force-pushed the fix/file-dependencies-lost branch from e2f1c91 to d5c5508 Compare November 4, 2024 11:47
@LingyuCoder LingyuCoder marked this pull request as ready for review November 5, 2024 05:53
@LingyuCoder LingyuCoder requested a review from h-a-n-a November 5, 2024 05:54
@LingyuCoder LingyuCoder requested a review from JSerFeng November 5, 2024 05:54
@LingyuCoder LingyuCoder merged commit 886a427 into main Nov 5, 2024
@LingyuCoder LingyuCoder deleted the fix/file-dependencies-lost branch November 5, 2024 06:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release: bug fix release: bug 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.

[Bug]: Errors in SCSS files stop tracking changes in all .scss files, while .js files continue to be tracked correctly.

2 participants