-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Open
Labels
bugmypy got something wrongmypy got something wrongtopic-join-v-unionUsing join vs. using unionsUsing join vs. using unionstopic-strict-optional
Description
While working on #3322 I have found this problem:
lst1 = [1, 'a', None]
lst2 = [1, None, 'a']
reveal_type(lst1) # builtins.list[builtins.object*]
reveal_type(lst2) # builtins.list[Union[builtins.str, builtins.int, builtins.None]]
This turns out to be the cause of spurious --strict-optional
errors I mentioned there.
hauntsaninja
Metadata
Metadata
Assignees
Labels
bugmypy got something wrongmypy got something wrongtopic-join-v-unionUsing join vs. using unionsUsing join vs. using unionstopic-strict-optional