-
-
Notifications
You must be signed in to change notification settings - Fork 150
Closed
Description
Describe the bug
A clear and concise description of what the bug is.
To Reproduce
- Provide a minimal runnable
pandas
example that is not properly checked by the stubs. - Indicate which type checker you are using (
mypy
orpyright
). - Show the error message received from that type checker while checking your example.
import pandas as pd
df = pd.DataFrame(data={"col1": [1, 2], "col2": [3, 4]})
df.index = [3, 4]
Error message is:
Cannot assign to attribute "index" for class "DataFrame" "list[int]" is not assignable to "Index[Any]"
Please complete the following information:
- OS: MacOS
- OS Version 15
- python version 3.13
- version of type checker 1.17.1
- version of installed
pandas-stubs
main
Additional context
Add any other context about the problem here.
Metadata
Metadata
Assignees
Labels
No labels