Skip to content

fix(@angular/build): invalidate cached SCSS errors when source files are corrected#32868

Closed
maruthang wants to merge 1 commit intoangular:mainfrom
maruthang:fix-32744-scss-error-cache
Closed

fix(@angular/build): invalidate cached SCSS errors when source files are corrected#32868
maruthang wants to merge 1 commit intoangular:mainfrom
maruthang:fix-32744-scss-error-cache

Conversation

@maruthang
Copy link
Copy Markdown
Contributor

PR Checklist

PR Type

  • Bugfix

What is the current behavior?

After fixing an SCSS compilation error, the build still shows the old error until a full restart. The cache invalidation fails because the file path is not normalized before lookup in the dependency map.

Issue Number: #32744

What is the new behavior?

Normalize the file path using the existing normalize() function before looking it up in the dependency map during cache invalidation, ensuring consistent path matching between storage and retrieval.

Does this PR introduce a breaking change?

  • Yes
  • No

…are corrected

Normalize the file path before looking it up in the dependency map
during cache invalidation. Without normalization, the path used for
invalidation could differ from the one stored during compilation,
causing stale error results to persist after fixing SCSS errors.

Fixes angular#32744
@google-cla
Copy link
Copy Markdown

google-cla bot commented Mar 27, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the MemoryLoadResultCache class to ensure that file paths are normalized before being used to invalidate cache entries in the #fileDependencies map. This change improves consistency in how paths are handled during cache invalidation. I have no feedback to provide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants