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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile errors in VS Code codebase with latest TS nightly #42225

Closed
mjbvz opened this issue Jan 6, 2021 · 3 comments
Closed

Compile errors in VS Code codebase with latest TS nightly #42225

mjbvz opened this issue Jan 6, 2021 · 3 comments
Labels
Duplicate An existing issue was already created

Comments

@mjbvz
Copy link
Contributor

mjbvz commented Jan 6, 2021

馃晽 Version & Regression Information

  • This changed between versions 4.2.0-dev.20201207 and 4.2.0-dev.20210105

Repo

  • Update VS Code to use the latest nightly TypeScript version (yarn add typescript@next)
  • Run compile in the codebase yarn run watch

Issue

This produces around 16 compile errors. Most of these look like false positives to me:

[21:49:47] Error: vscode/src/vs/workbench/contrib/files/browser/views/explorerViewer.ts(1232,24): The left-hand side of an 'instanceof' expression must be of type 'any', an object type or a type parameter.
[21:49:47] Error: vscode/src/vs/workbench/contrib/files/browser/views/explorerViewer.ts(1232,72): Argument of type 'undefined' is not assignable to parameter of type 'Uint8Array'.
[21:49:47] Error: vscode/src/vs/base/browser/ui/dropdown/dropdownActionViewItem.ts(176,99): Property 'getActions' does not exist on type 'readonly IAction[] | IActionProvider'.
  Property 'getActions' does not exist on type 'readonly IAction[]'.
[21:49:47] Error: vscode/src/vs/base/browser/ui/actionbar/actionbar.ts(267,9): Type '(readonly IAction[] & any[]) | (IAction & any[]) | (IAction | readonly IAction[])[]' is not assignable to type 'readonly IAction[]'.
  Type '(IAction | readonly IAction[])[]' is not assignable to type 'readonly IAction[]'.
    Type 'IAction | readonly IAction[]' is not assignable to type 'IAction'.
      Type 'readonly IAction[]' is missing the following properties from type 'IAction': id, label, tooltip, class, and 4 more.
[21:49:47] Error: vscode/src/vs/workbench/api/common/extHostTypeConverters.ts(1249,24): Property 'language' does not exist on type 'DocumentFilter | readonly (string | DocumentFilter)[]'.
  Property 'language' does not exist on type 'readonly (string | DocumentFilter)[]'.
[21:49:47] Error: vscode/src/vs/workbench/api/common/extHostTypeConverters.ts(1250,22): Property 'scheme' does not exist on type 'DocumentFilter | readonly (string | DocumentFilter)[]'.
  Property 'scheme' does not exist on type 'readonly (string | DocumentFilter)[]'.
[21:49:47] Error: vscode/src/vs/workbench/api/common/extHostTypeConverters.ts(1251,30): Property 'pattern' does not exist on type 'DocumentFilter | readonly (string | DocumentFilter)[]'.
  Property 'pattern' does not exist on type 'readonly (string | DocumentFilter)[]'.
[21:49:47] Error: vscode/src/vs/workbench/api/common/extHostTypeConverters.ts(1251,94): Property 'pattern' does not exist on type 'DocumentFilter | readonly (string | DocumentFilter)[]'.
  Property 'pattern' does not exist on type 'readonly (string | DocumentFilter)[]'.
[21:49:47] Error: vscode/src/vs/workbench/api/common/extHostTypeConverters.ts(1252,25): Property 'exclusive' does not exist on type 'DocumentFilter | readonly (string | DocumentFilter)[]'.
  Property 'exclusive' does not exist on type 'readonly (string | DocumentFilter)[]'.
[21:49:47] Error: vscode/src/vs/workbench/api/common/extHost.api.impl.ts(199,26): Property 'scheme' does not exist on type 'DocumentFilter | readonly (string | DocumentFilter)[]'.
  Property 'scheme' does not exist on type 'readonly (string | DocumentFilter)[]'.
[21:49:47] Error: vscode/src/vs/workbench/api/common/extHost.api.impl.ts(202,58): Property 'exclusive' does not exist on type 'DocumentFilter | readonly (string | DocumentFilter)[]'.
  Property 'exclusive' does not exist on type 'readonly (string | DocumentFilter)[]'.
[21:49:47] Error: vscode/src/vs/editor/common/modes/languageSelector.ts(58,11): Property 'language' does not exist on type 'LanguageFilter | readonly (string | LanguageFilter)[]'.
[21:49:47] Error: vscode/src/vs/editor/common/modes/languageSelector.ts(58,21): Property 'pattern' does not exist on type 'LanguageFilter | readonly (string | LanguageFilter)[]'.
[21:49:47] Error: vscode/src/vs/editor/common/modes/languageSelector.ts(58,30): Property 'scheme' does not exist on type 'LanguageFilter | readonly (string | LanguageFilter)[]'.
[21:49:47] Error: vscode/src/vs/editor/common/modes/languageSelector.ts(58,38): Property 'hasAccessToAllModels' does not exist on type 'LanguageFilter | readonly (string | LanguageFilter)[]'.
[21:49:47] Error: vscode/src/vs/editor/common/modes/languageFeatureRegistry.ts(28,21): Property 'exclusive' does not exist on type 'LanguageFilter | readonly (string | LanguageFilter)[]'.
  Property 'exclusive' does not exist on type 'readonly (string | LanguageFilter)[]'.
@mjbvz
Copy link
Contributor Author

mjbvz commented Jan 6, 2021

Note that after installing typescript@next, you may run into this compile error: google/tsec#20 (which is not related to VS Code directly)

@ajafff
Copy link
Contributor

ajafff commented Jan 6, 2021

Duplicate of #41808

@RyanCavanaugh RyanCavanaugh added the Duplicate An existing issue was already created label Jan 6, 2021
@typescript-bot
Copy link
Collaborator

This issue has been marked as a 'Duplicate' and has seen no recent activity. It has been automatically closed for house-keeping purposes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Duplicate An existing issue was already created
Projects
None yet
Development

No branches or pull requests

4 participants