Skip to content

Handle module node found error reporting in incremental and watch scneario #54115

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

Merged
merged 6 commits into from
May 9, 2023

Conversation

sheetalkamat
Copy link
Member

@sheetalkamat sheetalkamat commented May 3, 2023

With this, the diagnostic chain has repopulateInfo property if present will be used by incremental builder to update the diagnostic chain.
I didnt think it was right to get new errors again from checker just so error reporting is correct and resulting in more work, so went ahead with approach of diagnostic chain having this info.
This change has following changes to make everything come together:

  1. ModuleNodeFound chain is now a helper and sets repopulate info which can be used by anyone to get the latest chain.
  2. In the tsbuildinfo we save this info instead of chain message, so that we can get the correct diagnostic when getting the errors from buildinfo for the file.
  3. In tsc --watch scenario we need to repopulate using existing diagnostic and source file
  4. failed lookups and affected locations of node10Result are accumulated in the resolution itself so that it can be watched. We also watch node10Result as if it was failed lookup.

Fixes #52810

@typescript-bot typescript-bot added Author: Team For Uncommitted Bug PR for untriaged, rejected, closed or missing bug labels May 3, 2023
@sheetalkamat sheetalkamat merged commit 8b825f7 into main May 9, 2023
@sheetalkamat sheetalkamat deleted the node10Result branch May 9, 2023 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Author: Team For Uncommitted Bug PR for untriaged, rejected, closed or missing bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Node10Result on resolvedModule issues
4 participants