pytorch/torch/_dynamo/variables
Lucas Kabela 4a7bc1d522 [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569)
Provides type coverage to ~3000 LOC and 200 methods in  `torch/_dynamo/variables/`

This is the first part of the final step to having 100% strict type coverage in dynamo - see previous comments in https://github.com/pytorch/pytorch/pull/166535 (combined into this one PR because ghstack was giving issues...)

### Coverage report:
```
mypy torch_dynamo/variables --linecount-report /tmp/coverage_log
```
Compare before to after - we go from 3826 to 7221 lines covered

Pull Request resolved: https://github.com/pytorch/pytorch/pull/166569
Approved by: https://github.com/williamwen42, https://github.com/Skylion007
2025-10-31 20:42:27 +00:00
..
__init__.py [user-streams] Move StreamContextVariable into streams module (#164343) 2025-10-29 02:49:54 +00:00
base.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
builder.py Revert "[pytree] add treespec_{leaf,tuple,dict} functions for args_spec modification (#160843)" 2025-10-31 18:31:32 +00:00
builtin.py [dynamo] Implement iter with a polyfill (#162768) 2025-10-29 21:54:37 +00:00
constant.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
ctx_manager.py [user-streams] Move StreamContextVariable into streams module (#164343) 2025-10-29 02:49:54 +00:00
dicts.py [3/N] fix typo in other folders (#166606) 2025-10-30 10:30:40 +00:00
distributed.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
functions.py [dynamo] Move more FUNCTION_MATCH to CLOSURE_MATCH (#166444) 2025-10-28 23:19:42 +00:00
higher_order_ops.py Revert "[pytree] add treespec_{leaf,tuple,dict} functions for args_spec modification (#160843)" 2025-10-31 18:31:32 +00:00
iter.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
lazy.py Fix pyrefly ignores 1/n (#166239) 2025-10-26 00:44:10 +00:00
lists.py [dynamo] Fix ListIterator tracking mutations to original list (#166350) 2025-10-29 21:54:37 +00:00
misc.py [dynamo] support tracing new typing union syntax X | Y (#166599) 2025-10-30 23:59:27 +00:00
nn_module.py [dynamo] Add __iter__ for iterable VariableTrackers (#166349) 2025-10-29 21:54:37 +00:00
optimizer.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
script_object.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
sdpa.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
streams.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
tensor.py [dynamo] Add __iter__ for iterable VariableTrackers (#166349) 2025-10-29 21:54:37 +00:00
torch_function.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
torch.py [BE][Typing][Dynamo] Type misc files in torch/_dynamo/variables/ (#166569) 2025-10-31 20:42:27 +00:00
user_defined.py Revert "[user-streams] Fix stream graph output semantics (#164819)" 2025-10-30 16:53:32 +00:00