Skip to content
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

[wip] Shared resolutions in tsserver #55968

Draft
wants to merge 21 commits into
base: main
Choose a base branch
from
Draft

Conversation

sheetalkamat
Copy link
Member

Still working and creating PR to do testing as i push commits
Rework of #55067

@typescript-bot typescript-bot added Author: Team For Uncommitted Bug PR for untriaged, rejected, closed or missing bug labels Oct 3, 2023
@typescript-bot
Copy link
Collaborator

Looks like you're introducing a change to the public API surface area. If this includes breaking changes, please document them on our wiki's API Breaking Changes page.

Also, please make sure @DanielRosenwasser and @RyanCavanaugh are aware of the changes, just as a heads up.

First unresolved import gets the typing file into cache and sets it as root,
This results in scheduling new typing request with that unresolved import missing
The result will come back with typing file that is omitted, so root file will change but file will still be part of program so its not really removed from program
Also cache the inferred type acquition for inferred project
…pings cache

This change finally makes all tests pass incremental tests for matching resolutions and program structuture
…eed to update last cached unresolved imports just because we have new program
…s in the program

This shows cache is holding onto resolutions that are no longer needed by program because either those modules arent present in file or is determined to be ambient resolution
…ns are reused/are resolved to ambient module names
…ay instead of defering external module reoslutions to watch all failed lookup locations
But when do we gc Resolution caches esp for non relative names etc?
Also TODO:: handle change in module reosolution options
Postpone stopping watching resolutions as they can still be shared from different file
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.

None yet

2 participants