Skip to content

Conversation

@sheetalkamat
Copy link
Member

Fixes #56266

@typescript-bot typescript-bot added Author: Team For Milestone Bug PRs that fix a bug with a specific milestone labels Nov 14, 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.

"response": {
"changes": [],
"commands": [
{
Copy link
Member Author

Choose a reason for hiding this comment

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

Should these be deduplicated? If yes, at the end or during addition?
(irrespective of that we do need the fix to TI adapter to handle the correct promise resolution)

Copy link
Member

Choose a reason for hiding this comment

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

Probably? I'm not familiar enough with this to know for sure...

Copy link
Member Author

Choose a reason for hiding this comment

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

May be @sandersn

Copy link
Member

Choose a reason for hiding this comment

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

I'm guessing that this will run two npm installs, at once probably, and should be deduped. It seems safer, and just as easy, to do it on addition, but I could be wrong. It looks like the key of the new Map might need to be based on the package name instead of a numeric id.

@zkat worked on this code much more recently than I have and might have additional thoughts.

Copy link
Member Author

Choose a reason for hiding this comment

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

its possible to have duplicate "npm install requests" if i clicked "fix all" command multiple times right? So it has to be numeric id and installer handles the multiple installs for same package

Copy link
Member Author

Choose a reason for hiding this comment

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

The deduped result would be nice but wondering if it really matters

Copy link
Member

Choose a reason for hiding this comment

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

It'd be equivalent to running two npm install X commands at once, right? If a manual test of that shows that npm handles that case on its own, I think it's fine to have ATA allow dupes.

Copy link
Member Author

Choose a reason for hiding this comment

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

Its does

@sheetalkamat sheetalkamat merged commit 29bb857 into main Nov 16, 2023
@sheetalkamat sheetalkamat deleted the installPackage branch November 16, 2023 00:13
@microsoft microsoft locked as resolved and limited conversation to collaborators Oct 16, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Author: Team For Milestone Bug PRs that fix a bug with a specific milestone

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Unexpected error diagnostics in Typescript 5.2.2

6 participants