Skip to content

🤖 User test baselines have changed #26117

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

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
Exit Code: 1
Standard output:
node_modules/@types/react-native/index.d.ts(3895,26): error TS2693: 'setImmediate' only refers to a type, but is being used as a value here.
node_modules/@types/react-native/index.d.ts(3896,28): error TS2693: 'clearImmediate' only refers to a type, but is being used as a value here.
Copy link
Member

Choose a reason for hiding this comment

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

I am really unsure what is going on here. setImmediate and clearImmediate come from @types/node and shouldn't have anything in the type space because they are functions (although setImmediate has a merged namespace, it's a value namespace).

Copy link
Member

Choose a reason for hiding this comment

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

If there's no @types/node, then it could be coming from dom.generated.d.ts, which did delete a bunch of references recently.




Standard error:
3 changes: 3 additions & 0 deletions tests/baselines/reference/user/axios-src.log
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ lib/axios.js(41,7): error TS2339: Property 'CancelToken' does not exist on type
lib/axios.js(42,7): error TS2339: Property 'isCancel' does not exist on type 'Axios'.
lib/axios.js(45,7): error TS2339: Property 'all' does not exist on type 'Axios'.
lib/axios.js(48,7): error TS2339: Property 'spread' does not exist on type 'Axios'.
lib/cancel/CancelToken.js(23,15): error TS2339: Property 'reason' does not exist on type 'CancelToken'.
lib/cancel/CancelToken.js(28,11): error TS2339: Property 'reason' does not exist on type 'CancelToken'.
lib/cancel/CancelToken.js(29,26): error TS2339: Property 'reason' does not exist on type 'CancelToken'.
Copy link
Member

Choose a reason for hiding this comment

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

this is now typed because CancelToken has an @class tag.

Note that this, and the existing two errors, is a result of not tracking this property assignments through aliasing:

var token = this
executor(function (message) {
  if (token.reason) { return }
  token.reason = new Cancel(message)
})

If you switch to an arrow function and remove the aliasing, we infer this correctly:

executor((message) => {
  if (this.reason) { return }
  this.reason = new Cancel(message)
})

lib/cancel/CancelToken.js(37,12): error TS2339: Property 'reason' does not exist on type 'CancelToken'.
lib/cancel/CancelToken.js(38,16): error TS2339: Property 'reason' does not exist on type 'CancelToken'.
lib/core/enhanceError.js(14,9): error TS2339: Property 'config' does not exist on type 'Error'.
Expand Down
260 changes: 172 additions & 88 deletions tests/baselines/reference/user/chrome-devtools-frontend.log

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion tests/baselines/reference/user/debug.log
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ node_modules/debug/src/browser.js(14,41): error TS2304: Cannot find name 'chrome
node_modules/debug/src/browser.js(15,21): error TS2304: Cannot find name 'chrome'.
node_modules/debug/src/browser.js(48,47): error TS2339: Property 'process' does not exist on type 'Window'.
node_modules/debug/src/browser.js(48,65): error TS2339: Property 'process' does not exist on type 'Window'.
node_modules/debug/src/browser.js(59,139): error TS2551: Property 'WebkitAppearance' does not exist on type 'CSSStyleDeclaration'. Did you mean 'webkitAppearance'?
node_modules/debug/src/browser.js(59,99): error TS2339: Property 'style' does not exist on type 'HTMLElement'.
node_modules/debug/src/browser.js(59,133): error TS2339: Property 'style' does not exist on type 'HTMLElement'.
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 not sure what is going on here either -- the lib.dom.d.ts didn't change around HTMLElement, and only to add an index signature. debug itself hasn't changed either. And I don't think document.documentElement was previously any by mistake, because the previous type error was on document.documentElement.style.

node_modules/debug/src/browser.js(61,73): error TS2339: Property 'firebug' does not exist on type 'Console'.
node_modules/debug/src/browser.js(187,13): error TS2304: Cannot find name 'LocalStorage'.
node_modules/debug/src/debug.js(25,1): error TS2323: Cannot redeclare exported variable 'names'.
Expand Down
14 changes: 8 additions & 6 deletions tests/baselines/reference/user/lodash.log
Original file line number Diff line number Diff line change
Expand Up @@ -100,15 +100,15 @@ node_modules/lodash/_createFlow.js(56,13): error TS2454: Variable 'wrapper' is u
node_modules/lodash/_createFlow.js(57,13): error TS2454: Variable 'wrapper' is used before being assigned.
node_modules/lodash/_createFlow.js(57,21): error TS2339: Property 'thru' does not exist on type 'LodashWrapper'.
node_modules/lodash/_createFlow.js(65,24): error TS2339: Property 'plant' does not exist on type 'LodashWrapper'.
node_modules/lodash/_createHybrid.js(44,49): error TS2345: Argument of type 'string | Function' is not assignable to parameter of type 'Function'.
node_modules/lodash/_createHybrid.js(44,49): error TS2345: Argument of type 'TimerHandler' is not assignable to parameter of type 'Function'.
Copy link
Member

Choose a reason for hiding this comment

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

generated d.ts now has an alias type TimerHandler = string | Function. This, uh, happens a lot in places that don't handle timers. I don't think it should be a built-in alias.

Type 'string' is not assignable to type 'Function'.
node_modules/lodash/_createHybrid.js(59,42): error TS2345: Argument of type 'any[] | undefined' is not assignable to parameter of type 'any[]'.
Type 'undefined' is not assignable to type 'any[]'.
node_modules/lodash/_createHybrid.js(62,52): error TS2345: Argument of type 'any[] | undefined' is not assignable to parameter of type 'any[]'.
Type 'undefined' is not assignable to type 'any[]'.
node_modules/lodash/_createHybrid.js(64,15): error TS2454: Variable 'holdersCount' is used before being assigned.
node_modules/lodash/_createHybrid.js(65,31): error TS2532: Object is possibly 'undefined'.
node_modules/lodash/_createHybrid.js(68,9): error TS2345: Argument of type 'string | Function' is not assignable to parameter of type 'Function'.
node_modules/lodash/_createHybrid.js(68,9): error TS2345: Argument of type 'TimerHandler' is not assignable to parameter of type 'Function'.
Type 'string' is not assignable to type 'Function'.
node_modules/lodash/_createHybrid.js(68,46): error TS2339: Property 'placeholder' does not exist on type '(...args: any[]) => any'.
node_modules/lodash/_createHybrid.js(69,40): error TS2532: Object is possibly 'undefined'.
Expand All @@ -117,14 +117,14 @@ node_modules/lodash/_createHybrid.js(81,18): error TS2532: Object is possibly 'u
node_modules/lodash/_createHybrid.js(82,7): error TS2322: Type 'number | undefined' is not assignable to type 'number'.
Type 'undefined' is not assignable to type 'number'.
node_modules/lodash/_createWrap.js(71,38): error TS2554: Expected 0 arguments, but got 1.
node_modules/lodash/_createWrap.js(94,29): error TS2345: Argument of type 'string | Function' is not assignable to parameter of type 'Function'.
node_modules/lodash/_createWrap.js(94,29): error TS2345: Argument of type 'TimerHandler' is not assignable to parameter of type 'Function'.
Type 'string' is not assignable to type 'Function'.
node_modules/lodash/_createWrap.js(96,26): error TS2345: Argument of type 'string | Function' is not assignable to parameter of type 'Function'.
node_modules/lodash/_createWrap.js(96,26): error TS2345: Argument of type 'TimerHandler' is not assignable to parameter of type 'Function'.
Type 'string' is not assignable to type 'Function'.
node_modules/lodash/_createWrap.js(97,100): error TS2532: Object is possibly 'undefined'.
node_modules/lodash/_createWrap.js(98,28): error TS2345: Argument of type 'string | Function' is not assignable to parameter of type 'Function'.
node_modules/lodash/_createWrap.js(98,28): error TS2345: Argument of type 'TimerHandler' is not assignable to parameter of type 'Function'.
Type 'string' is not assignable to type 'Function'.
node_modules/lodash/_createWrap.js(103,51): error TS2345: Argument of type 'string | Function' is not assignable to parameter of type 'Function'.
node_modules/lodash/_createWrap.js(103,51): error TS2345: Argument of type 'TimerHandler' is not assignable to parameter of type 'Function'.
Type 'string' is not assignable to type 'Function'.
node_modules/lodash/_customDefaultsMerge.js(22,35): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'number'.
node_modules/lodash/_customOmitClone.js(9,20): error TS8024: JSDoc '@param' tag has name 'key', but there is no parameter with that name.
Expand Down Expand Up @@ -165,6 +165,7 @@ node_modules/lodash/bind.js(55,6): error TS2339: Property 'placeholder' does not
node_modules/lodash/bindKey.js(62,53): error TS2454: Variable 'holders' is used before being assigned.
node_modules/lodash/bindKey.js(66,9): error TS2339: Property 'placeholder' does not exist on type 'Function'.
node_modules/lodash/castArray.js(10,15): error TS8029: JSDoc '@param' tag has name 'value', but there is no parameter with that name. It would match 'arguments' if it had an array type.
node_modules/lodash/chain.js(33,16): error TS2348: Value of type 'typeof lodash' is not callable. Did you mean to include 'new'?
Copy link
Member

Choose a reason for hiding this comment

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

in wrapperLodash.js, function lodash is marked with @constructor, despite not referencing this. It is literally a wrapper for calling return new LodashWrapper along with a few other cases. It's not a constructor function, but a factory function.

node_modules/lodash/chunk.js(20,10): error TS1003: Identifier expected.
node_modules/lodash/chunk.js(20,10): error TS8024: JSDoc '@param' tag has name '', but there is no parameter with that name.
node_modules/lodash/clamp.js(25,5): error TS2322: Type 'number | undefined' is not assignable to type 'number'.
Expand Down Expand Up @@ -214,6 +215,7 @@ node_modules/lodash/core.js(1446,24): error TS2532: Object is possibly 'undefine
node_modules/lodash/core.js(1449,17): error TS2538: Type 'undefined' cannot be used as an index type.
node_modules/lodash/core.js(1566,33): error TS2554: Expected 1 arguments, but got 2.
node_modules/lodash/core.js(1709,41): error TS2532: Object is possibly 'undefined'.
node_modules/lodash/core.js(1745,18): error TS2348: Value of type 'typeof lodash' is not callable. Did you mean to include 'new'?
node_modules/lodash/core.js(1872,12): error TS1003: Identifier expected.
node_modules/lodash/core.js(1872,12): error TS8024: JSDoc '@param' tag has name '', but there is no parameter with that name.
node_modules/lodash/core.js(2142,12): error TS1003: Identifier expected.
Expand Down
2 changes: 2 additions & 0 deletions tests/baselines/reference/user/npm.log
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ node_modules/npm/bin/npm-cli.js(132,17): error TS2339: Property 'config' does no
node_modules/npm/bin/npm-cli.js(134,17): error TS2339: Property 'config' does not exist on type 'typeof EventEmitter'.
node_modules/npm/bin/npm-cli.js(136,17): error TS2339: Property 'config' does not exist on type 'typeof EventEmitter'.
node_modules/npm/html/static/toc.js(3,40): error TS2531: Object is possibly 'null'.
node_modules/npm/html/static/toc.js(11,7): error TS2339: Property 'innerHTML' does not exist on type 'HTMLUListElement'.
node_modules/npm/html/static/toc.js(28,3): error TS2531: Object is possibly 'null'.
Copy link
Member

Choose a reason for hiding this comment

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

These two are a result of generated DOM changes too.

node_modules/npm/lib/access.js(58,46): error TS2339: Property 'config' does not exist on type 'typeof EventEmitter'.
node_modules/npm/lib/access.js(65,18): error TS2339: Property 'registry' does not exist on type 'typeof EventEmitter'.
node_modules/npm/lib/access.js(115,19): error TS2339: Property 'prefix' does not exist on type 'typeof EventEmitter'.
Expand Down
3 changes: 3 additions & 0 deletions tests/baselines/reference/user/puppeteer.log
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ lib/FrameManager.js(28,15): error TS2503: Cannot find namespace 'Protocol'.
lib/FrameManager.js(54,15): error TS2503: Cannot find namespace 'Protocol'.
lib/FrameManager.js(76,15): error TS2503: Cannot find namespace 'Protocol'.
lib/FrameManager.js(127,15): error TS2503: Cannot find namespace 'Protocol'.
lib/FrameManager.js(410,44): error TS2339: Property 'outerHTML' does not exist on type 'HTMLElement'.
lib/FrameManager.js(685,57): error TS2345: Argument of type 'string | number | Function' is not assignable to parameter of type 'number'.
Type 'string' is not assignable to type 'number'.
lib/FrameManager.js(773,15): error TS2503: Cannot find namespace 'Protocol'.
lib/NetworkManager.js(129,15): error TS2503: Cannot find namespace 'Protocol'.
lib/NetworkManager.js(174,15): error TS2503: Cannot find namespace 'Protocol'.
Expand Down