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 alias support #71

Open
snorkysnark opened this issue Sep 23, 2024 · 0 comments
Open

Type alias support #71

snorkysnark opened this issue Sep 23, 2024 · 0 comments

Comments

@snorkysnark
Copy link

For type aliases, one can either use the 3.12 syntax:

type Resolves[T] = T | OutputOf

which results in an error: WARNING: ralsei.graph.outputof: ralsei.graph.outputof: 'Resolves' is unknown [autodoc2.all_resolve]

or the older

Resolves: TypeAlias = T | OutputOf

which works but obscures the value: ralsei.graph.outputof.Resolves : TypeAlias = None

So there isn't a good way to document type aliases and what they refer to.
Sure you can replace them with autodoc2_replace_annotations, but I'd like the user to know what aliases exist as part of my API

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant