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

Warning: Failed to convert type node with kind #1457

Closed
kaiyoma opened this issue Jan 6, 2021 · 2 comments
Closed

Warning: Failed to convert type node with kind #1457

kaiyoma opened this issue Jan 6, 2021 · 2 comments
Labels
bug Functionality does not match expectation

Comments

@kaiyoma
Copy link

kaiyoma commented Jan 6, 2021

Expected Behavior

Typedoc should generate docs without any warnings.

Actual Behavior

Typedoc spits out several warnings:

Warning: Failed to convert type node with kind: RestType and text ...unknown[]. Please report a bug.
        .../packages/cv-utils/types/utility.ts:8:10
Warning: Failed to convert type node with kind: RestType and text ...infer _I. Please report a bug.
        .../packages/cv-utils/types/utility.ts:15:81
Warning: Failed to convert type node with kind: RestType and text ...infer I. Please report a bug.
        .../packages/cv-utils/types/utility.ts:23:84
Warning: Failed to convert type node with kind: OptionalType and text unknown?. Please report a bug.
        .../packages/cv-utils/types/utility.ts:31:81
Warning: Failed to convert type node with kind: RestType and text ...infer T. Please report a bug.
        .../packages/cv-utils/types/utility.ts:32:11
Warning: Failed to convert type node with kind: RestType and text ...unknown[]. Please report a bug.
        .../packages/cv-utils/types/utility.ts:8:10
Warning: Failed to convert type node with kind: RestType and text ...infer _I. Please report a bug.
        .../packages/cv-utils/types/utility.ts:15:81
Warning: Failed to convert type node with kind: RestType and text ...infer I. Please report a bug.
        .../packages/cv-utils/types/utility.ts:23:84
Warning: Failed to convert type node with kind: OptionalType and text unknown?. Please report a bug.
        .../packages/cv-utils/types/utility.ts:31:81
Warning: Failed to convert type node with kind: RestType and text ...infer T. Please report a bug.
        .../packages/cv-utils/types/utility.ts:32:11

Steps to reproduce the bug

Here's one example of a utility type that's causing these warnings:

/** Head of an array type. */
export type Head<A extends unknown[] | readonly unknown[]> = Mutable<A> extends [
  infer H,
  ...unknown[]
]
  ? H
  : never;

Environment

  • Typedoc version: 0.20.13
  • TypeScript version: 4.1.3
  • Node.js version: 14.15.0
  • OS: Windows 10
@kaiyoma kaiyoma added the bug Functionality does not match expectation label Jan 6, 2021
@Gerrit0
Copy link
Collaborator

Gerrit0 commented Jan 8, 2021

Thanks for the repro!... Couldn't quite fix this tonight. Should be able to get to it tomorrow or Saturday.

@Gerrit0 Gerrit0 closed this as completed in 83d2a2c Jan 9, 2021
@Gerrit0
Copy link
Collaborator

Gerrit0 commented Jan 9, 2021

Fixed in 0.20.14 :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Functionality does not match expectation
Projects
None yet
Development

No branches or pull requests

2 participants