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

Type error beyond 3 levels of recursion #1221

Closed
kostasb opened this issue Oct 12, 2023 · 1 comment · Fixed by #1222
Closed

Type error beyond 3 levels of recursion #1221

kostasb opened this issue Oct 12, 2023 · 1 comment · Fixed by #1222
Labels
bug Something isn't working needs-triage

Comments

@kostasb
Copy link
Contributor

kostasb commented Oct 12, 2023

Describe the bug

The TS SDK encounters an error beyond 3 levels of recursion for linked columns.

Type '"two.three.four.id"' is not assignable to type 'SelectableColumnWithObjectNotation<OneRecord, []>'. Did you mean '"two.three.four"'?(28

image

@kostasb kostasb added the bug Something isn't working label Oct 12, 2023
@SferaDev
Copy link
Member

With TypeScript we cannot infer when to stop recursion. Each nested level adds a bigger amount of compute to the type checker and the LSP.

We decided to cut recursion because with some schemas that link to themselves (or to themselves in 2 levels) the IDE language services would crash itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs-triage
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants