Skip to content

Fix cases of type object handling for overloads#16168

Merged
hauntsaninja merged 2 commits intopython:masterfrom
hauntsaninja:type-object-handling
Oct 1, 2023
Merged

Fix cases of type object handling for overloads#16168
hauntsaninja merged 2 commits intopython:masterfrom
hauntsaninja:type-object-handling

Conversation

@hauntsaninja
Copy link
Copy Markdown
Collaborator

Fixes most of #12320. I didn't add tests for every code path because it's niche. I also didn't fix everything, in particular the cases where we proceed to use ret_type

Fixes most of python#12320. I didn't add tests for every code path because
it's niche. I also didn't fix everything, in particular the cases where
we proceed to use `ret_type`, or ones I thought were scary
@github-actions

This comment has been minimized.

@github-actions
Copy link
Copy Markdown
Contributor

Diff from mypy_primer, showing the effect of this PR on open source code:

hydra-zen (https://github.com/mit-ll-responsible-ai/hydra-zen)
- src/hydra_zen/structured_configs/_utils.py:341: error: Value of type "type[list[Any]]" is not indexable  [index]
+ src/hydra_zen/structured_configs/_utils.py:341: error: The type "type[list[Any]]" is not generic and not indexable  [misc]

@hauntsaninja hauntsaninja merged commit 3d3e482 into python:master Oct 1, 2023
@hauntsaninja hauntsaninja deleted the type-object-handling branch October 1, 2023 09:06
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

Successfully merging this pull request may close these issues.

2 participants