question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[NewErrors] 4.8.0-dev.20220609 vs 4.7.3

See original GitHub issue

The following errors were reported by 4.8.0-dev.20220609, but not by 4.7.3

kamranahmedse/developer-roadmap

tsconfig.json

  • error TS2344: Type 'K' does not satisfy the constraint 'Record<string, any>'.
    • file:///mnt/ts_downloads/developer-roadmap/node_modules/@chakra-ui/descendant/src/use-descendant.ts#L11
    • file:///mnt/ts_downloads/developer-roadmap/node_modules/@chakra-ui/descendant/src/use-descendant.ts#L87
    • file:///mnt/ts_downloads/developer-roadmap/node_modules/@chakra-ui/descendant/src/use-descendant.ts#L91

coder/code-server

7 of 57 projects failed to build with the old tsc

src/tsconfig.monaco.json

src/tsconfig.tsec.json

microsoft/playwright

4 of 9 projects failed to build with the old tsc

packages/html-reporter/tsconfig.json

vercel/hyper

2 of 3 projects failed to build with the old tsc

tsconfig.json

  • error TS2344: Type 'BaseType' does not satisfy the constraint 'Record<string | number, any>'.
    • file:///mnt/ts_downloads/hyper/app/node_modules/type-fest/ts41/get.d.ts#L93 in app/tsconfig.json
    • file:///mnt/ts_downloads/hyper/app/node_modules/type-fest/ts41/get.d.ts#L94 in app/tsconfig.json
  • error TS2344: Type 'T' does not satisfy the constraint 'Record<string, any>'.
    • file:///mnt/ts_downloads/hyper/app/node_modules/conf/dist/source/types.d.ts#L201 in app/tsconfig.json

react-hook-form/react-hook-form

2 of 3 projects failed to build with the old tsc

tsconfig.json

typeorm/typeorm

tsconfig.json

mobxjs/mobx

7 of 9 projects failed to build with the old tsc

packages/mobx/tsconfig.json

palantir/blueprint

11 of 25 projects failed to build with the old tsc

packages/datetime/src/tsconfig.json

packages/select/src/tsconfig.json

apollographql/apollo-client

tsconfig.json

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
ahejlsbergcommented, Jun 9, 2022

@DanielRosenwasser I’m pretty sure that comes from #49119 (which incorporated the change from #48366). When checking whether an unconstrained type parameter T is assignable to some type X, we used to check whether {} is assignable to X. We now check whether unknown is assignable to X, and in this case it isn’t because T could be undefined or null. This seems like a very legit error.

1reaction
andrewbranchcommented, Jun 9, 2022

It’s nonsense because I didn’t add // @strictNullChecks: true to the repro. But I wonder what change it thinks it picked up on, hah

Read more comments on GitHub >

github_iconTop Results From Across the Web

Untitled
Learning the basics and advanced types of TypeScript will be very ... request on Jun 13 [NewErrors] 4.8.0-dev.20220609 vs 4.7.3 microsoft/TypeScript#49461 ...
Read more >
Untitled
We could always tell TypeScript to pipe down and use a type assertion to ... on Jun 13 [NewErrors] 4.8.0-dev.20220609 vs 4.7.3 microsoft/TypeScript#49461 ......
Read more >
Untitled
In some languages such as Java, methods or functions can provide type ... on Jun 13 [NewErrors] 4.8.0-dev.20220609 vs 4.7.3 microsoft/TypeScript#49461 ...
Read more >
Untitled
A TypeError may be thrown when: an operand or argument passed to a function ... on Jun 13 [NewErrors] 4.8.0-dev.20220609 vs 4.7.3 microsoft/TypeScript#49461 ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found