pandas MultiIndex.levels return type not correct #412
Labels
fixed in next version (main)
A fix has been implemented and will appear in an upcoming version
typestub
Issue relating to our bundled type stubs
Environment data
Expected behaviour
No error
Actual behaviour
reports
Issue here is that
MultiIndex.levels
acts like a python property with the internal decorator of@cache_readonly
, except you are not allowed to set it. Not sure what to do about that part, but below is a fix that works for the most common usage. It just would not report a typing error on a line such asind.levels = [3, 4]
, which is not allowed.Possible fix:
The text was updated successfully, but these errors were encountered: