Conversation
This comment has been minimized.
This comment has been minimized.
|
According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉 |
| # ideally this would be `_SpecialForm` (Union) | ||
| assert_type(union_type | Literal[1], types.UnionType | Any) | ||
| assert_type(union_type | Literal[1], types.UnionType | Any) # pyright: ignore[reportAssertTypeFailure] | ||
| # assert_type(union_type | Literal[1], types.UnionType | type[Literal[1]]) # this is what pyright infers |
There was a problem hiding this comment.
type[Literal[1]] is a nonsense type -- it's quite unclear what it would/should mean. I don't think it should be valid to parameterize type with Literal[...]. So we could possibly report this as a bug to pyright.
There was a problem hiding this comment.
I was wondering about that (but I'm not to familiar with "meta types"). Would you report it? I think a report by you would be clearer than me only half-understanding what I write. I would then just update the comment with a link to the issue.
|
Why are you updating to 1.1.413 and not 1.1.414? |
Matching Renovate's minimum release age rules. Although we should consider lowering them for type checkers. |
|
Oh I see, strange then that Renovate's own PR did update to 1.1.414.
Not sure about that, type checkers could also get compromised |
Closes: #16408
The first version will mostly likely break on non-pyright type checkers.