You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
typeddicts_operations.py:29:8 TypedDict initialization error [55]: Expected type `int` for `Movie` field `year` but got `float`.
11
11
typeddicts_operations.py:32:8 TypedDict initialization error [55]: TypedDict `Movie` has no field `other`.
12
12
typeddicts_operations.py:37:4 Incompatible variable type [9]: movie is declared to have type `Movie` but is used as type `Dict[str, Union[int, str]]`.
13
-
typeddicts_operations.py:47:0 Undefined attribute [16]: `Movie` has no attribute `clear`.
14
-
typeddicts_operations.py:49:0 Invalid TypedDict operation [54]: Cannot delete required field `name` from TypedDict `Movie`.
15
-
typeddicts_operations.py:62:0 Undefined attribute [16]: `MovieOptional` has no attribute `clear`.
13
+
typeddicts_operations.py:40:19 TypedDict accessed with a non-literal [26]: TypedDict key must be a string literal. Expected one of ('name', 'year').
14
+
typeddicts_operations.py:41:23 TypedDict accessed with a non-literal [26]: TypedDict key must be a string literal. Expected one of ('name', 'year').
15
+
typeddicts_operations.py:44:4 Revealed type [-1]: Revealed type for `existing_movie[variable_key]` is `str`.
16
+
typeddicts_operations.py:44:31 TypedDict accessed with a non-literal [26]: TypedDict key must be a string literal. Expected one of ('name', 'year').
17
+
typeddicts_operations.py:47:4 Revealed type [-1]: Revealed type for `variable_key in existing_movie` is `bool`.
18
+
typeddicts_operations.py:58:0 Revealed type [-1]: Revealed type for `"other" in movie` is `bool`.
19
+
typeddicts_operations.py:60:0 Undefined attribute [16]: `Movie` has no attribute `clear`.
20
+
typeddicts_operations.py:61:0 Undefined attribute [16]: `Movie` has no attribute `popitem`.
21
+
typeddicts_operations.py:63:0 Invalid TypedDict operation [54]: Cannot delete required field `name` from TypedDict `Movie`.
22
+
typeddicts_operations.py:80:0 Revealed type [-1]: Revealed type for `movie_optional.get("other")` is `typing.Optional[object]`.
23
+
typeddicts_operations.py:83:0 Revealed type [-1]: Revealed type for `"name" in movie_optional` is `bool`.
24
+
typeddicts_operations.py:86:0 Revealed type [-1]: Revealed type for `"other" in movie_optional` is `bool`.
25
+
typeddicts_operations.py:88:0 Undefined attribute [16]: `MovieOptional` has no attribute `clear`.
26
+
typeddicts_operations.py:89:0 Undefined attribute [16]: `MovieOptional` has no attribute `popitem`.
27
+
typeddicts_operations.py:96:4 Incompatible variable type [9]: movie_optional is declared to have type `MovieOptional` but is used as type `Dict[str, Union[int, str]]`.
28
+
typeddicts_operations.py:99:28 TypedDict accessed with a non-literal [26]: TypedDict key must be a string literal. Expected one of ('name', 'year').
29
+
typeddicts_operations.py:100:32 TypedDict accessed with a non-literal [26]: TypedDict key must be a string literal. Expected one of ('name', 'year').
30
+
typeddicts_operations.py:103:4 Revealed type [-1]: Revealed type for `existing_optional_movie[variable_key]` is `str`.
31
+
typeddicts_operations.py:103:40 TypedDict accessed with a non-literal [26]: TypedDict key must be a string literal. Expected one of ('name', 'year').
32
+
typeddicts_operations.py:106:4 Revealed type [-1]: Revealed type for `variable_key in existing_optional_movie` is `bool`.
typeddicts_operations.py:60:1: \u001b[1m\u001b[31merror\u001b[39m\u001b[0m: in <module>: str [assert-type]
29
+
typeddicts_operations.py:40:5: \u001b[1m\u001b[31merror\u001b[39m\u001b[0m: in func1: TypedDict Movie requires all keys to be constant strings [typed-dict-error]
typeddicts_operations.py:41:9: \u001b[1m\u001b[31merror\u001b[39m\u001b[0m: in func1: TypedDict Movie requires all keys to be constant strings [typed-dict-error]
typeddicts_operations.py:44:17: \u001b[1m\u001b[31merror\u001b[39m\u001b[0m: in func1: TypedDict Movie requires all keys to be constant strings [typed-dict-error]
typeddicts_operations.py:99:5: \u001b[1m\u001b[31merror\u001b[39m\u001b[0m: in func2: TypedDict MovieOptional requires all keys to be constant strings [typed-dict-error]
typeddicts_operations.py:100:9: \u001b[1m\u001b[31merror\u001b[39m\u001b[0m: in func2: TypedDict MovieOptional requires all keys to be constant strings [typed-dict-error]
90
+
91
+
del existing_optional_movie[variable_key] # E: variable key
typeddicts_operations.py:103:17: \u001b[1m\u001b[31merror\u001b[39m\u001b[0m: in func2: TypedDict MovieOptional requires all keys to be constant strings [typed-dict-error]
95
+
96
+
reveal_type(existing_optional_movie[variable_key]) # E
0 commit comments